Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 11 additions & 0 deletions .claude/launch.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
{
"version": "0.0.1",
"configurations": [
{
"name": "solid-docs-dev",
"runtimeExecutable": "pnpm",
"runtimeArgs": ["dev"],
"port": 3000
}
]
}
2 changes: 1 addition & 1 deletion osmium/src/ui/layout/main-header.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ export function MainHeader(_props: MainHeaderProps) {
)}
</Show>

<div class="order- flex basis-0 items-center justify-end gap-4 lg:order-2">
<div class="flex items-center justify-end gap-4 lg:col-start-3">
<ClientSearch />
<a
href={`${config().themeConfig?.github}/${project().projects[project().current].path || "solid"}`}
Expand Down
6 changes: 3 additions & 3 deletions src/routes/(0)index.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -18,13 +18,13 @@ description: >-
---

:::note[These docs cover the release candidate]
Solid 2.0 is a release candidate (RC).
Solid 2.0 is in its release candidate (RC) phase.
APIs may change before the stable release, and packages from the coordinated RC must use compatible versions.
For Solid 1.x, SolidStart, and the current stable ecosystem, see the [current Solid documentation](https://docs.solidjs.com/).
:::

Solid is a framework for building user interfaces on the web.
Solid 2.0 is a coordinated release of the whole platform: the core library, rendering, routing, head management, and the Vite plugin ship together and are designed to work together.
Solid 2.0 is a coordinated release of the whole platform: the core library, rendering, routing, head management, and the Vite plugin are designed to work together.

You can try Solid in the [playground](https://playground.solidjs.com/) or [start a project](/getting-started/quick-start) right away.

Expand All @@ -35,4 +35,4 @@ You can try Solid in the [playground](https://playground.solidjs.com/) or [start
- [Building apps](/building-apps/app-structure): the application layer — structure, server functions, sessions, environment, deployment.
- [Routing](/routing/overview): how routers plug in, with guides for Solid Router and TanStack Router.
- [Migration](/migration/from-solid-1): moving from Solid 1.x, SolidStart, and earlier ecosystem versions.
- Reference: API documentation for each package, organized by import specifier.
- [Reference](/reference/solid-js/reactivity/create-effect): API documentation for each package, organized by import specifier.
8 changes: 4 additions & 4 deletions src/routes/(1)getting-started/(0)quick-start.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -11,15 +11,15 @@ These versions satisfy the Vite 8 runtime requirement used by the maintained tem
Run the Solid CLI:

```bash
npm init solid
npm init solid@latest
```

Use the equivalent command for another package manager:

```bash
pnpm create solid
yarn create solid
bun create solid
pnpm create solid@latest
yarn create solid@latest
bun create solid@latest
```

Choose the `basic` project shape when the CLI prompts you.
Expand Down
4 changes: 4 additions & 0 deletions src/routes/(2)concepts/(0)reactivity.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,10 @@ console.log(model.fullName()); // "Grace Lovelace"
model.dispose();
```

:::note
`model.fullName()` doesn't update until you call `flush()`.
:::

Use a memo when multiple consumers need the same derivation or when the derived value should form an equality boundary in the reactive graph.
An expression used in only one JSX location can often read its sources directly.

Expand Down
5 changes: 2 additions & 3 deletions src/routes/(2)concepts/(3)async-reactivity.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -88,9 +88,6 @@ import { Loading, isPending } from "solid-js";
The result becomes `true` when another answer for that expression is in flight and has not revealed.
If the expression has no settled answer yet, its read still follows the surrounding `Loading` path.

Read the async source itself.
Reading only an upstream input such as `id` cannot reveal whether a separate downstream computation is pending.

## Work rejects: `Errored`

If async work rejects, the error travels through the reactive graph.
Expand Down Expand Up @@ -305,6 +302,8 @@ If the next answer exists, `latest(user)` returns it before the held update comm
Otherwise, it returns the visible settled answer.
Before any answer exists, the read still follows the normal `Loading` path.

A common use case for `latest` is an autocomplete or typeahead interface that keeps results visible while the next value loads.

### Declare a committed first value

Most applications should let unresolved first reads reach a `Loading` boundary.
Expand Down
2 changes: 2 additions & 0 deletions src/routes/(3)building-apps/(3)server-functions.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -211,6 +211,8 @@ export const renameCurrentUser = action(async (form: FormData) => {
});
```

Place the `"use server"` directive inside the callback passed to `query()` or `action()`.

`query()` caches reads by its name and arguments and declares a wrapped server function as an HTTP `GET`.
`action()` tracks mutation submissions and applies response metadata to the router's query cache.
When the router registers its single-flight integration, an action response can carry refreshed route data with the mutation result.
Expand Down
2 changes: 1 addition & 1 deletion src/routes/(4)routing/(1)solid-router/(1)setup.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ description: "Install Solid Router, create a route tree, and mount the router in
Install Solid Router in a Solid 2 application:

```sh
pnpm add @solidjs/router
pnpm add @solidjs/router@next
```

Define the route tree and create the router at module scope:
Expand Down
Loading