Skip to content

Commit 183dbc3

Browse files
jog1tNathanFlurry
authored andcommitted
feat(devtools): add makeshift devtools
1 parent 2641cb4 commit 183dbc3

33 files changed

+678
-38
lines changed

biome.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
"**/*.js",
66
"**/*.json",
77
"**/*.ts",
8+
"rivetkit-typescript/packages/inspect/**/*",
89
"!engine/artifacts",
910
"!engine/sdks/typescript/api-full",
1011
"!engine/sdks/typescript/runner-protocol",

examples/chat-room/package.json

Lines changed: 2 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

examples/chat-room/src/frontend/main.tsx

Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

frontend/src/app/layout.tsx

Lines changed: 19 additions & 4 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

frontend/src/app/route-layout.tsx

Lines changed: 12 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

frontend/src/components/actors/actors-actor-details.tsx

Lines changed: 78 additions & 7 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

frontend/src/components/actors/worker/actor-worker-context.tsx

Lines changed: 14 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

frontend/src/components/theme.css

Lines changed: 2 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -1,27 +1,4 @@
1-
:root {
2-
--background: 0 0% 100%;
3-
--foreground: 20 14.3% 4.1%;
4-
--card: 0 0% 100%;
5-
--card-foreground: 20 14.3% 4.1%;
6-
--popover: 0 0% 100%;
7-
--popover-foreground: 20 14.3% 4.1%;
8-
--primary: 24.6 95% 53.1%;
9-
--primary-foreground: 60 9.1% 97.8%;
10-
--secondary: 60 4.8% 95.9%;
11-
--secondary-foreground: 24 9.8% 10%;
12-
--muted: 60 4.8% 95.9%;
13-
--muted-foreground: 25 5.3% 44.7%;
14-
--muted-destructive: 0 72% 30%;
15-
--accent: 60 4.8% 95.9%;
16-
--accent-foreground: 24 9.8% 10%;
17-
--destructive: 0 84.2% 60.2%;
18-
--destructive-foreground: 60 9.1% 97.8%;
19-
--border: 20 5.9% 90%;
20-
--input: 20 5.9% 90%;
21-
--ring: 24.6 95% 53.1%;
22-
--radius: 0.5rem;
23-
}
24-
:root[class~="dark"] {
1+
:root[class~="dark"], :root, :host {
252
--background: 20 14.3% 4.1%;
263
--foreground: 60 9.1% 97.8%;
274
--card: 0 9.09% 6.47%;
@@ -43,6 +20,7 @@
4320
--input: 12 6.5% 15.1%;
4421
--ring: 18.59deg 100% 50%;
4522
--background-main: 0 7.14% 5.49%;
23+
--radius: 0.5rem;
4624
}
4725

4826
:root {
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
# Logs
2+
logs
3+
*.log
4+
npm-debug.log*
5+
yarn-debug.log*
6+
yarn-error.log*
7+
pnpm-debug.log*
8+
lerna-debug.log*
9+
10+
node_modules
11+
dist
12+
dist-ssr
13+
*.local
14+
15+
# Editor directories and files
16+
.vscode/*
17+
!.vscode/extensions.json
18+
.idea
19+
.DS_Store
20+
*.suo
21+
*.ntvs*
22+
*.njsproj
23+
*.sln
24+
*.sw?
Lines changed: 73 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,73 @@
1+
# React + TypeScript + Vite
2+
3+
This template provides a minimal setup to get React working in Vite with HMR and some ESLint rules.
4+
5+
Currently, two official plugins are available:
6+
7+
- [@vitejs/plugin-react](https://github.com/vitejs/vite-plugin-react/blob/main/packages/plugin-react) uses [Babel](https://babeljs.io/) (or [oxc](https://oxc.rs) when used in [rolldown-vite](https://vite.dev/guide/rolldown)) for Fast Refresh
8+
- [@vitejs/plugin-react-swc](https://github.com/vitejs/vite-plugin-react/blob/main/packages/plugin-react-swc) uses [SWC](https://swc.rs/) for Fast Refresh
9+
10+
## React Compiler
11+
12+
The React Compiler is not enabled on this template because of its impact on dev & build performances. To add it, see [this documentation](https://react.dev/learn/react-compiler/installation).
13+
14+
## Expanding the ESLint configuration
15+
16+
If you are developing a production application, we recommend updating the configuration to enable type-aware lint rules:
17+
18+
```js
19+
export default defineConfig([
20+
globalIgnores(['dist']),
21+
{
22+
files: ['**/*.{ts,tsx}'],
23+
extends: [
24+
// Other configs...
25+
26+
// Remove tseslint.configs.recommended and replace with this
27+
tseslint.configs.recommendedTypeChecked,
28+
// Alternatively, use this for stricter rules
29+
tseslint.configs.strictTypeChecked,
30+
// Optionally, add this for stylistic rules
31+
tseslint.configs.stylisticTypeChecked,
32+
33+
// Other configs...
34+
],
35+
languageOptions: {
36+
parserOptions: {
37+
project: ['./tsconfig.node.json', './tsconfig.app.json'],
38+
tsconfigRootDir: import.meta.dirname,
39+
},
40+
// other options...
41+
},
42+
},
43+
])
44+
```
45+
46+
You can also install [eslint-plugin-react-x](https://github.com/Rel1cx/eslint-react/tree/main/packages/plugins/eslint-plugin-react-x) and [eslint-plugin-react-dom](https://github.com/Rel1cx/eslint-react/tree/main/packages/plugins/eslint-plugin-react-dom) for React-specific lint rules:
47+
48+
```js
49+
// eslint.config.js
50+
import reactX from 'eslint-plugin-react-x'
51+
import reactDom from 'eslint-plugin-react-dom'
52+
53+
export default defineConfig([
54+
globalIgnores(['dist']),
55+
{
56+
files: ['**/*.{ts,tsx}'],
57+
extends: [
58+
// Other configs...
59+
// Enable lint rules for React
60+
reactX.configs['recommended-typescript'],
61+
// Enable lint rules for React DOM
62+
reactDom.configs.recommended,
63+
],
64+
languageOptions: {
65+
parserOptions: {
66+
project: ['./tsconfig.node.json', './tsconfig.app.json'],
67+
tsconfigRootDir: import.meta.dirname,
68+
},
69+
// other options...
70+
},
71+
},
72+
])
73+
```

0 commit comments

Comments
 (0)