Example app with Stitches
This example features how to use Stitches with Remix.
- app/
- styles/
- client.context.tsx
- stitches.config.ts
- entry.client.tsx
- entry.server.tsx
- root.tsx
client.context.tsx
- Keeps the client context of styles and to reset styles sheets after every interaction into the state.stitches.config.ts
- Keeps the Stitches configuration that is shared into the project.entry.client.tsx
- Every time that styles update and be re-injected it sets the Stitches sheet to a React state.entry.server.tsx
- Create the markup with the styles injected to serve on the server response.
Open this example on CodeSandbox:
First, run the development server:
npm run dev
# or
yarn dev
Open http://localhost:3000 with your browser to see the result.
You can start editing the page by modifying app/routes/_index.tsx
. The page auto-updates as you edit the file.
dev
: runs your application onlocalhost:3000
build
: creates the production build versionstart
: starts a simple server with the build production code