@hexidecibel/companion 0.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (109) hide show
  1. package/dist/__tests__/task-parser.test.d.ts +2 -0
  2. package/dist/__tests__/task-parser.test.d.ts.map +1 -0
  3. package/dist/__tests__/task-parser.test.js +79 -0
  4. package/dist/__tests__/task-parser.test.js.map +1 -0
  5. package/dist/anthropic-usage.d.ts +5 -0
  6. package/dist/anthropic-usage.d.ts.map +1 -0
  7. package/dist/anthropic-usage.js +112 -0
  8. package/dist/anthropic-usage.js.map +1 -0
  9. package/dist/cert-generator.d.ts +15 -0
  10. package/dist/cert-generator.d.ts.map +1 -0
  11. package/dist/cert-generator.js +298 -0
  12. package/dist/cert-generator.js.map +1 -0
  13. package/dist/config.d.ts +4 -0
  14. package/dist/config.d.ts.map +1 -0
  15. package/dist/config.js +122 -0
  16. package/dist/config.js.map +1 -0
  17. package/dist/encryption.d.ts +28 -0
  18. package/dist/encryption.d.ts.map +1 -0
  19. package/dist/encryption.js +95 -0
  20. package/dist/encryption.js.map +1 -0
  21. package/dist/index.d.ts +3 -0
  22. package/dist/index.d.ts.map +1 -0
  23. package/dist/index.js +211 -0
  24. package/dist/index.js.map +1 -0
  25. package/dist/input-injector.d.ts +21 -0
  26. package/dist/input-injector.d.ts.map +1 -0
  27. package/dist/input-injector.js +126 -0
  28. package/dist/input-injector.js.map +1 -0
  29. package/dist/mdns.d.ts +11 -0
  30. package/dist/mdns.d.ts.map +1 -0
  31. package/dist/mdns.js +93 -0
  32. package/dist/mdns.js.map +1 -0
  33. package/dist/parser.d.ts +43 -0
  34. package/dist/parser.d.ts.map +1 -0
  35. package/dist/parser.js +800 -0
  36. package/dist/parser.js.map +1 -0
  37. package/dist/push.d.ts +38 -0
  38. package/dist/push.d.ts.map +1 -0
  39. package/dist/push.js +359 -0
  40. package/dist/push.js.map +1 -0
  41. package/dist/qr-server.d.ts +13 -0
  42. package/dist/qr-server.d.ts.map +1 -0
  43. package/dist/qr-server.js +421 -0
  44. package/dist/qr-server.js.map +1 -0
  45. package/dist/scaffold/generator.d.ts +11 -0
  46. package/dist/scaffold/generator.d.ts.map +1 -0
  47. package/dist/scaffold/generator.js +206 -0
  48. package/dist/scaffold/generator.js.map +1 -0
  49. package/dist/scaffold/templates/index.d.ts +5 -0
  50. package/dist/scaffold/templates/index.d.ts.map +1 -0
  51. package/dist/scaffold/templates/index.js +22 -0
  52. package/dist/scaffold/templates/index.js.map +1 -0
  53. package/dist/scaffold/templates/node-express.d.ts +3 -0
  54. package/dist/scaffold/templates/node-express.d.ts.map +1 -0
  55. package/dist/scaffold/templates/node-express.js +218 -0
  56. package/dist/scaffold/templates/node-express.js.map +1 -0
  57. package/dist/scaffold/templates/python-fastapi.d.ts +3 -0
  58. package/dist/scaffold/templates/python-fastapi.d.ts.map +1 -0
  59. package/dist/scaffold/templates/python-fastapi.js +302 -0
  60. package/dist/scaffold/templates/python-fastapi.js.map +1 -0
  61. package/dist/scaffold/templates/react-mui-website.d.ts +3 -0
  62. package/dist/scaffold/templates/react-mui-website.d.ts.map +1 -0
  63. package/dist/scaffold/templates/react-mui-website.js +405 -0
  64. package/dist/scaffold/templates/react-mui-website.js.map +1 -0
  65. package/dist/scaffold/templates/react-typescript.d.ts +3 -0
  66. package/dist/scaffold/templates/react-typescript.d.ts.map +1 -0
  67. package/dist/scaffold/templates/react-typescript.js +275 -0
  68. package/dist/scaffold/templates/react-typescript.js.map +1 -0
  69. package/dist/scaffold/types.d.ts +55 -0
  70. package/dist/scaffold/types.d.ts.map +1 -0
  71. package/dist/scaffold/types.js +3 -0
  72. package/dist/scaffold/types.js.map +1 -0
  73. package/dist/subagent-watcher.d.ts +24 -0
  74. package/dist/subagent-watcher.d.ts.map +1 -0
  75. package/dist/subagent-watcher.js +307 -0
  76. package/dist/subagent-watcher.js.map +1 -0
  77. package/dist/tls.d.ts +10 -0
  78. package/dist/tls.d.ts.map +1 -0
  79. package/dist/tls.js +77 -0
  80. package/dist/tls.js.map +1 -0
  81. package/dist/tmux-manager.d.ts +71 -0
  82. package/dist/tmux-manager.d.ts.map +1 -0
  83. package/dist/tmux-manager.js +243 -0
  84. package/dist/tmux-manager.js.map +1 -0
  85. package/dist/tool-config.d.ts +33 -0
  86. package/dist/tool-config.d.ts.map +1 -0
  87. package/dist/tool-config.js +211 -0
  88. package/dist/tool-config.js.map +1 -0
  89. package/dist/types.d.ts +218 -0
  90. package/dist/types.d.ts.map +1 -0
  91. package/dist/types.js +3 -0
  92. package/dist/types.js.map +1 -0
  93. package/dist/watcher.d.ts +63 -0
  94. package/dist/watcher.d.ts.map +1 -0
  95. package/dist/watcher.js +596 -0
  96. package/dist/watcher.js.map +1 -0
  97. package/dist/watcher.test.d.ts +2 -0
  98. package/dist/watcher.test.d.ts.map +1 -0
  99. package/dist/watcher.test.js +110 -0
  100. package/dist/watcher.test.js.map +1 -0
  101. package/dist/websocket.d.ts +62 -0
  102. package/dist/websocket.d.ts.map +1 -0
  103. package/dist/websocket.js +1695 -0
  104. package/dist/websocket.js.map +1 -0
  105. package/package.json +71 -0
  106. package/scripts/build.sh +23 -0
  107. package/scripts/install-remote.sh +18 -0
  108. package/scripts/install.sh +558 -0
  109. package/scripts/uninstall.sh +113 -0
@@ -0,0 +1,405 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.reactMuiWebsiteTemplate = void 0;
4
+ exports.reactMuiWebsiteTemplate = {
5
+ id: 'react-mui-website',
6
+ name: 'React + MUI Website',
7
+ description: 'Multi-page website with React, TypeScript, Material UI, and routing',
8
+ type: 'frontend',
9
+ icon: '🎨',
10
+ tags: ['react', 'typescript', 'mui', 'material-ui', 'website', 'frontend'],
11
+ files: [
12
+ {
13
+ path: 'package.json',
14
+ template: `{
15
+ "name": "{{projectName}}",
16
+ "version": "0.1.0",
17
+ "private": true,
18
+ "dependencies": {
19
+ "@emotion/react": "^11.13.0",
20
+ "@emotion/styled": "^11.13.0",
21
+ "@mui/icons-material": "^6.1.0",
22
+ "@mui/material": "^6.1.0",
23
+ "react": "^18.3.1",
24
+ "react-dom": "^18.3.1",
25
+ "react-router-dom": "^6.28.0"
26
+ },
27
+ "devDependencies": {
28
+ "@types/react": "^18.3.12",
29
+ "@types/react-dom": "^18.3.1",
30
+ "@vitejs/plugin-react": "^4.3.3",
31
+ "typescript": "~5.6.2",
32
+ "vite": "^5.4.10"
33
+ },
34
+ "scripts": {
35
+ "dev": "vite",
36
+ "build": "tsc -b && vite build",
37
+ "preview": "vite preview"
38
+ }
39
+ }`,
40
+ },
41
+ {
42
+ path: 'tsconfig.json',
43
+ template: `{
44
+ "compilerOptions": {
45
+ "target": "ES2020",
46
+ "useDefineForClassFields": true,
47
+ "lib": ["ES2020", "DOM", "DOM.Iterable"],
48
+ "module": "ESNext",
49
+ "skipLibCheck": true,
50
+ "moduleResolution": "bundler",
51
+ "allowImportingTsExtensions": true,
52
+ "isolatedModules": true,
53
+ "moduleDetection": "force",
54
+ "noEmit": true,
55
+ "jsx": "react-jsx",
56
+ "strict": true,
57
+ "noUnusedLocals": true,
58
+ "noUnusedParameters": true,
59
+ "noFallthroughCasesInSwitch": true
60
+ },
61
+ "include": ["src"]
62
+ }`,
63
+ },
64
+ {
65
+ path: 'vite.config.ts',
66
+ template: `import { defineConfig } from 'vite'
67
+ import react from '@vitejs/plugin-react'
68
+
69
+ export default defineConfig({
70
+ plugins: [react()],
71
+ })`,
72
+ },
73
+ {
74
+ path: 'index.html',
75
+ template: `<!doctype html>
76
+ <html lang="en">
77
+ <head>
78
+ <meta charset="UTF-8" />
79
+ <link rel="icon" href="/favicon.ico" />
80
+ <meta name="viewport" content="width=device-width, initial-scale=1.0" />
81
+ <title>{{projectName}}</title>
82
+ </head>
83
+ <body>
84
+ <div id="root"></div>
85
+ <script type="module" src="/src/main.tsx"></script>
86
+ </body>
87
+ </html>`,
88
+ },
89
+ {
90
+ path: 'src/main.tsx',
91
+ template: `import { StrictMode } from 'react'
92
+ import { createRoot } from 'react-dom/client'
93
+ import { BrowserRouter } from 'react-router-dom'
94
+ import { ThemeProvider, CssBaseline } from '@mui/material'
95
+ import { theme } from './theme'
96
+ import App from './App'
97
+
98
+ createRoot(document.getElementById('root')!).render(
99
+ <StrictMode>
100
+ <BrowserRouter>
101
+ <ThemeProvider theme={theme}>
102
+ <CssBaseline />
103
+ <App />
104
+ </ThemeProvider>
105
+ </BrowserRouter>
106
+ </StrictMode>,
107
+ )`,
108
+ },
109
+ {
110
+ path: 'src/theme.ts',
111
+ template: `import { createTheme } from '@mui/material/styles'
112
+
113
+ export const theme = createTheme({
114
+ palette: {
115
+ mode: 'dark',
116
+ primary: {
117
+ main: '#90caf9',
118
+ },
119
+ secondary: {
120
+ main: '#f48fb1',
121
+ },
122
+ background: {
123
+ default: '#121212',
124
+ paper: '#1e1e1e',
125
+ },
126
+ },
127
+ typography: {
128
+ fontFamily: '"Inter", "Roboto", "Helvetica", "Arial", sans-serif',
129
+ h1: {
130
+ fontSize: '2.5rem',
131
+ fontWeight: 700,
132
+ },
133
+ h2: {
134
+ fontSize: '2rem',
135
+ fontWeight: 600,
136
+ },
137
+ },
138
+ })`,
139
+ },
140
+ {
141
+ path: 'src/App.tsx',
142
+ template: `import { Routes, Route } from 'react-router-dom'
143
+ import { Box } from '@mui/material'
144
+ import { Navbar } from './components/Navbar'
145
+ import { Home } from './pages/Home'
146
+ import { About } from './pages/About'
147
+ import { Contact } from './pages/Contact'
148
+
149
+ function App() {
150
+ return (
151
+ <Box sx={{ minHeight: '100vh', display: 'flex', flexDirection: 'column' }}>
152
+ <Navbar />
153
+ <Box component="main" sx={{ flex: 1, py: 4 }}>
154
+ <Routes>
155
+ <Route path="/" element={<Home />} />
156
+ <Route path="/about" element={<About />} />
157
+ <Route path="/contact" element={<Contact />} />
158
+ </Routes>
159
+ </Box>
160
+ </Box>
161
+ )
162
+ }
163
+
164
+ export default App`,
165
+ },
166
+ {
167
+ path: 'src/components/Navbar.tsx',
168
+ template: `import { AppBar, Toolbar, Typography, Button, Container, Box } from '@mui/material'
169
+ import { Link as RouterLink } from 'react-router-dom'
170
+
171
+ export function Navbar() {
172
+ return (
173
+ <AppBar position="static" color="transparent" elevation={0}>
174
+ <Container maxWidth="lg">
175
+ <Toolbar disableGutters>
176
+ <Typography
177
+ variant="h6"
178
+ component={RouterLink}
179
+ to="/"
180
+ sx={{ textDecoration: 'none', color: 'inherit', flexGrow: 1 }}
181
+ >
182
+ {{projectName}}
183
+ </Typography>
184
+ <Box sx={{ display: 'flex', gap: 2 }}>
185
+ <Button component={RouterLink} to="/" color="inherit">
186
+ Home
187
+ </Button>
188
+ <Button component={RouterLink} to="/about" color="inherit">
189
+ About
190
+ </Button>
191
+ <Button component={RouterLink} to="/contact" color="inherit">
192
+ Contact
193
+ </Button>
194
+ </Box>
195
+ </Toolbar>
196
+ </Container>
197
+ </AppBar>
198
+ )
199
+ }`,
200
+ },
201
+ {
202
+ path: 'src/pages/Home.tsx',
203
+ template: `import { Container, Typography, Box, Button } from '@mui/material'
204
+ import { Link as RouterLink } from 'react-router-dom'
205
+
206
+ export function Home() {
207
+ return (
208
+ <Container maxWidth="lg">
209
+ <Box sx={{ textAlign: 'center', py: 8 }}>
210
+ <Typography variant="h1" gutterBottom>
211
+ Welcome to {{projectName}}
212
+ </Typography>
213
+ <Typography variant="h5" color="text.secondary" paragraph>
214
+ {{projectDescription}}
215
+ </Typography>
216
+ <Box sx={{ mt: 4 }}>
217
+ <Button
218
+ variant="contained"
219
+ size="large"
220
+ component={RouterLink}
221
+ to="/about"
222
+ >
223
+ Learn More
224
+ </Button>
225
+ </Box>
226
+ </Box>
227
+ </Container>
228
+ )
229
+ }`,
230
+ },
231
+ {
232
+ path: 'src/pages/About.tsx',
233
+ template: `import { Container, Typography, Box, Paper } from '@mui/material'
234
+
235
+ export function About() {
236
+ return (
237
+ <Container maxWidth="md">
238
+ <Paper sx={{ p: 4 }}>
239
+ <Typography variant="h2" gutterBottom>
240
+ About
241
+ </Typography>
242
+ <Typography variant="body1" paragraph>
243
+ This is the about page for {{projectName}}.
244
+ </Typography>
245
+ <Typography variant="body1" paragraph>
246
+ {{projectDescription}}
247
+ </Typography>
248
+ </Paper>
249
+ </Container>
250
+ )
251
+ }`,
252
+ },
253
+ {
254
+ path: 'src/pages/Contact.tsx',
255
+ template: `import { Container, Typography, Box, Paper, TextField, Button } from '@mui/material'
256
+ import { useState } from 'react'
257
+
258
+ export function Contact() {
259
+ const [formData, setFormData] = useState({ name: '', email: '', message: '' })
260
+
261
+ const handleSubmit = (e: React.FormEvent) => {
262
+ e.preventDefault()
263
+ console.log('Form submitted:', formData)
264
+ // Add your form submission logic here
265
+ }
266
+
267
+ return (
268
+ <Container maxWidth="sm">
269
+ <Paper sx={{ p: 4 }}>
270
+ <Typography variant="h2" gutterBottom>
271
+ Contact Us
272
+ </Typography>
273
+ <Box component="form" onSubmit={handleSubmit} sx={{ display: 'flex', flexDirection: 'column', gap: 2 }}>
274
+ <TextField
275
+ label="Name"
276
+ value={formData.name}
277
+ onChange={(e) => setFormData({ ...formData, name: e.target.value })}
278
+ required
279
+ fullWidth
280
+ />
281
+ <TextField
282
+ label="Email"
283
+ type="email"
284
+ value={formData.email}
285
+ onChange={(e) => setFormData({ ...formData, email: e.target.value })}
286
+ required
287
+ fullWidth
288
+ />
289
+ <TextField
290
+ label="Message"
291
+ multiline
292
+ rows={4}
293
+ value={formData.message}
294
+ onChange={(e) => setFormData({ ...formData, message: e.target.value })}
295
+ required
296
+ fullWidth
297
+ />
298
+ <Button type="submit" variant="contained" size="large">
299
+ Send Message
300
+ </Button>
301
+ </Box>
302
+ </Paper>
303
+ </Container>
304
+ )
305
+ }`,
306
+ },
307
+ {
308
+ path: 'src/vite-env.d.ts',
309
+ template: `/// <reference types="vite/client" />`,
310
+ },
311
+ {
312
+ path: '.gitignore',
313
+ template: `# Dependencies
314
+ node_modules
315
+
316
+ # Build
317
+ dist
318
+ dist-ssr
319
+ *.local
320
+
321
+ # Editor
322
+ .vscode/*
323
+ !.vscode/extensions.json
324
+ .idea
325
+
326
+ # Logs
327
+ *.log
328
+ npm-debug.log*
329
+
330
+ # OS
331
+ .DS_Store`,
332
+ },
333
+ {
334
+ path: 'CLAUDE.md',
335
+ template: `# {{projectName}}
336
+
337
+ {{projectDescription}}
338
+
339
+ ## Tech Stack
340
+ - React 18 with TypeScript
341
+ - Material UI (MUI) v6 for components
342
+ - React Router v6 for navigation
343
+ - Vite for build tooling
344
+
345
+ ## Project Structure
346
+ \`\`\`
347
+ src/
348
+ ├── main.tsx # Entry point
349
+ ├── App.tsx # Root component with routing
350
+ ├── theme.ts # MUI theme customization
351
+ ├── components/ # Reusable components
352
+ │ └── Navbar.tsx
353
+ └── pages/ # Page components
354
+ ├── Home.tsx
355
+ ├── About.tsx
356
+ └── Contact.tsx
357
+ \`\`\`
358
+
359
+ ## Commands
360
+ - \`npm run dev\` - Start dev server
361
+ - \`npm run build\` - Build for production
362
+ - \`npm run preview\` - Preview production build
363
+
364
+ ## Development Notes
365
+ - Add new pages in \`src/pages/\`
366
+ - Add reusable components in \`src/components/\`
367
+ - Customize theme in \`src/theme.ts\`
368
+ - Add routes in \`App.tsx\``,
369
+ },
370
+ {
371
+ path: 'README.md',
372
+ template: `# {{projectName}}
373
+
374
+ {{projectDescription}}
375
+
376
+ ## Getting Started
377
+
378
+ \`\`\`bash
379
+ npm install
380
+ npm run dev
381
+ \`\`\`
382
+
383
+ ## Pages
384
+
385
+ - **Home** - Landing page
386
+ - **About** - About page
387
+ - **Contact** - Contact form
388
+
389
+ ## Tech Stack
390
+
391
+ - React + TypeScript
392
+ - Material UI
393
+ - React Router
394
+ - Vite`,
395
+ },
396
+ ],
397
+ postCreate: [
398
+ {
399
+ command: 'npm install',
400
+ description: 'Installing dependencies',
401
+ },
402
+ ],
403
+ recommendedSkills: ['build', 'dev'],
404
+ };
405
+ //# sourceMappingURL=react-mui-website.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"react-mui-website.js","sourceRoot":"","sources":["../../../src/scaffold/templates/react-mui-website.ts"],"names":[],"mappings":";;;AAEa,QAAA,uBAAuB,GAAkB;IACpD,EAAE,EAAE,mBAAmB;IACvB,IAAI,EAAE,qBAAqB;IAC3B,WAAW,EAAE,qEAAqE;IAClF,IAAI,EAAE,UAAU;IAChB,IAAI,EAAE,IAAI;IACV,IAAI,EAAE,CAAC,OAAO,EAAE,YAAY,EAAE,KAAK,EAAE,aAAa,EAAE,SAAS,EAAE,UAAU,CAAC;IAC1E,KAAK,EAAE;QACL;YACE,IAAI,EAAE,cAAc;YACpB,QAAQ,EAAE;;;;;;;;;;;;;;;;;;;;;;;;;EAyBd;SACG;QACD;YACE,IAAI,EAAE,eAAe;YACrB,QAAQ,EAAE;;;;;;;;;;;;;;;;;;;EAmBd;SACG;QACD;YACE,IAAI,EAAE,gBAAgB;YACtB,QAAQ,EAAE;;;;;GAKb;SACE;QACD;YACE,IAAI,EAAE,YAAY;YAClB,QAAQ,EAAE;;;;;;;;;;;;QAYR;SACH;QACD;YACE,IAAI,EAAE,cAAc;YACpB,QAAQ,EAAE;;;;;;;;;;;;;;;;EAgBd;SACG;QACD;YACE,IAAI,EAAE,cAAc;YACpB,QAAQ,EAAE;;;;;;;;;;;;;;;;;;;;;;;;;;;GA2Bb;SACE;QACD;YACE,IAAI,EAAE,aAAa;YACnB,QAAQ,EAAE;;;;;;;;;;;;;;;;;;;;;;mBAsBG;SACd;QACD;YACE,IAAI,EAAE,2BAA2B;YACjC,QAAQ,EAAE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EA+Bd;SACG;QACD;YACE,IAAI,EAAE,oBAAoB;YAC1B,QAAQ,EAAE;;;;;;;;;;;;;;;;;;;;;;;;;;EA0Bd;SACG;QACD;YACE,IAAI,EAAE,qBAAqB;YAC3B,QAAQ,EAAE;;;;;;;;;;;;;;;;;;EAkBd;SACG;QACD;YACE,IAAI,EAAE,uBAAuB;YAC7B,QAAQ,EAAE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAkDd;SACG;QACD;YACE,IAAI,EAAE,mBAAmB;YACzB,QAAQ,EAAE,uCAAuC;SAClD;QACD;YACE,IAAI,EAAE,YAAY;YAClB,QAAQ,EAAE;;;;;;;;;;;;;;;;;;UAkBN;SACL;QACD;YACE,IAAI,EAAE,WAAW;YACjB,QAAQ,EAAE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;4BAiCY;SACvB;QACD;YACE,IAAI,EAAE,WAAW;YACjB,QAAQ,EAAE;;;;;;;;;;;;;;;;;;;;;;OAsBT;SACF;KACF;IACD,UAAU,EAAE;QACV;YACE,OAAO,EAAE,aAAa;YACtB,WAAW,EAAE,yBAAyB;SACvC;KACF;IACD,iBAAiB,EAAE,CAAC,OAAO,EAAE,KAAK,CAAC;CACpC,CAAC"}
@@ -0,0 +1,3 @@
1
+ import { StackTemplate } from '../types';
2
+ export declare const reactTypescriptTemplate: StackTemplate;
3
+ //# sourceMappingURL=react-typescript.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"react-typescript.d.ts","sourceRoot":"","sources":["../../../src/scaffold/templates/react-typescript.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AAEzC,eAAO,MAAM,uBAAuB,EAAE,aA8QrC,CAAC"}
@@ -0,0 +1,275 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.reactTypescriptTemplate = void 0;
4
+ exports.reactTypescriptTemplate = {
5
+ id: 'react-typescript',
6
+ name: 'React + TypeScript',
7
+ description: 'Modern React app with TypeScript, Vite, and best practices',
8
+ type: 'frontend',
9
+ icon: '⚛️',
10
+ tags: ['react', 'typescript', 'vite', 'frontend'],
11
+ files: [
12
+ {
13
+ path: 'package.json',
14
+ template: `{
15
+ "name": "{{projectName}}",
16
+ "private": true,
17
+ "version": "0.0.0",
18
+ "type": "module",
19
+ "scripts": {
20
+ "dev": "vite",
21
+ "build": "tsc -b && vite build",
22
+ "lint": "eslint .",
23
+ "preview": "vite preview",
24
+ "test": "vitest"
25
+ },
26
+ "dependencies": {
27
+ "react": "^18.3.1",
28
+ "react-dom": "^18.3.1"
29
+ },
30
+ "devDependencies": {
31
+ "@eslint/js": "^9.13.0",
32
+ "@types/react": "^18.3.12",
33
+ "@types/react-dom": "^18.3.1",
34
+ "@vitejs/plugin-react": "^4.3.3",
35
+ "eslint": "^9.13.0",
36
+ "eslint-plugin-react-hooks": "^5.0.0",
37
+ "eslint-plugin-react-refresh": "^0.4.14",
38
+ "globals": "^15.11.0",
39
+ "typescript": "~5.6.2",
40
+ "typescript-eslint": "^8.11.0",
41
+ "vite": "^5.4.10",
42
+ "vitest": "^2.1.4"
43
+ }
44
+ }`,
45
+ },
46
+ {
47
+ path: 'tsconfig.json',
48
+ template: `{
49
+ "compilerOptions": {
50
+ "target": "ES2020",
51
+ "useDefineForClassFields": true,
52
+ "lib": ["ES2020", "DOM", "DOM.Iterable"],
53
+ "module": "ESNext",
54
+ "skipLibCheck": true,
55
+ "moduleResolution": "bundler",
56
+ "allowImportingTsExtensions": true,
57
+ "isolatedModules": true,
58
+ "moduleDetection": "force",
59
+ "noEmit": true,
60
+ "jsx": "react-jsx",
61
+ "strict": true,
62
+ "noUnusedLocals": true,
63
+ "noUnusedParameters": true,
64
+ "noFallthroughCasesInSwitch": true,
65
+ "noUncheckedSideEffectImports": true
66
+ },
67
+ "include": ["src"]
68
+ }`,
69
+ },
70
+ {
71
+ path: 'vite.config.ts',
72
+ template: `import { defineConfig } from 'vite'
73
+ import react from '@vitejs/plugin-react'
74
+
75
+ export default defineConfig({
76
+ plugins: [react()],
77
+ })`,
78
+ },
79
+ {
80
+ path: 'index.html',
81
+ template: `<!doctype html>
82
+ <html lang="en">
83
+ <head>
84
+ <meta charset="UTF-8" />
85
+ <link rel="icon" type="image/svg+xml" href="/vite.svg" />
86
+ <meta name="viewport" content="width=device-width, initial-scale=1.0" />
87
+ <title>{{projectName}}</title>
88
+ </head>
89
+ <body>
90
+ <div id="root"></div>
91
+ <script type="module" src="/src/main.tsx"></script>
92
+ </body>
93
+ </html>`,
94
+ },
95
+ {
96
+ path: 'src/main.tsx',
97
+ template: `import { StrictMode } from 'react'
98
+ import { createRoot } from 'react-dom/client'
99
+ import App from './App'
100
+ import './index.css'
101
+
102
+ createRoot(document.getElementById('root')!).render(
103
+ <StrictMode>
104
+ <App />
105
+ </StrictMode>,
106
+ )`,
107
+ },
108
+ {
109
+ path: 'src/App.tsx',
110
+ template: `import { useState } from 'react'
111
+ import './App.css'
112
+
113
+ function App() {
114
+ const [count, setCount] = useState(0)
115
+
116
+ return (
117
+ <div className="app">
118
+ <h1>{{projectName}}</h1>
119
+ <p>{{projectDescription}}</p>
120
+ <div className="card">
121
+ <button onClick={() => setCount((count) => count + 1)}>
122
+ count is {count}
123
+ </button>
124
+ </div>
125
+ </div>
126
+ )
127
+ }
128
+
129
+ export default App`,
130
+ },
131
+ {
132
+ path: 'src/App.css',
133
+ template: `.app {
134
+ max-width: 1280px;
135
+ margin: 0 auto;
136
+ padding: 2rem;
137
+ text-align: center;
138
+ }
139
+
140
+ .card {
141
+ padding: 2em;
142
+ }
143
+
144
+ button {
145
+ border-radius: 8px;
146
+ border: 1px solid transparent;
147
+ padding: 0.6em 1.2em;
148
+ font-size: 1em;
149
+ font-weight: 500;
150
+ font-family: inherit;
151
+ background-color: #1a1a1a;
152
+ color: #fff;
153
+ cursor: pointer;
154
+ transition: border-color 0.25s;
155
+ }
156
+
157
+ button:hover {
158
+ border-color: #646cff;
159
+ }
160
+
161
+ button:focus,
162
+ button:focus-visible {
163
+ outline: 4px auto -webkit-focus-ring-color;
164
+ }`,
165
+ },
166
+ {
167
+ path: 'src/index.css',
168
+ template: `:root {
169
+ font-family: Inter, system-ui, Avenir, Helvetica, Arial, sans-serif;
170
+ line-height: 1.5;
171
+ font-weight: 400;
172
+ color-scheme: light dark;
173
+ color: rgba(255, 255, 255, 0.87);
174
+ background-color: #242424;
175
+ font-synthesis: none;
176
+ text-rendering: optimizeLegibility;
177
+ -webkit-font-smoothing: antialiased;
178
+ -moz-osx-font-smoothing: grayscale;
179
+ }
180
+
181
+ body {
182
+ margin: 0;
183
+ min-width: 320px;
184
+ min-height: 100vh;
185
+ }`,
186
+ },
187
+ {
188
+ path: 'src/vite-env.d.ts',
189
+ template: `/// <reference types="vite/client" />`,
190
+ },
191
+ {
192
+ path: '.gitignore',
193
+ template: `# Dependencies
194
+ node_modules
195
+
196
+ # Build
197
+ dist
198
+ dist-ssr
199
+ *.local
200
+
201
+ # Editor
202
+ .vscode/*
203
+ !.vscode/extensions.json
204
+ .idea
205
+
206
+ # Logs
207
+ *.log
208
+ npm-debug.log*
209
+
210
+ # OS
211
+ .DS_Store`,
212
+ },
213
+ {
214
+ path: 'CLAUDE.md',
215
+ template: `# {{projectName}}
216
+
217
+ {{projectDescription}}
218
+
219
+ ## Tech Stack
220
+ - React 18 with TypeScript
221
+ - Vite for build tooling
222
+ - Vitest for testing
223
+
224
+ ## Project Structure
225
+ \`\`\`
226
+ src/
227
+ ├── main.tsx # Entry point
228
+ ├── App.tsx # Main component
229
+ ├── App.css # Component styles
230
+ └── index.css # Global styles
231
+ \`\`\`
232
+
233
+ ## Commands
234
+ - \`npm run dev\` - Start dev server
235
+ - \`npm run build\` - Build for production
236
+ - \`npm run test\` - Run tests
237
+ - \`npm run lint\` - Run linter
238
+
239
+ ## Development Notes
240
+ - Components go in \`src/components/\`
241
+ - Hooks go in \`src/hooks/\`
242
+ - Types go in \`src/types/\`
243
+ - Services/API calls go in \`src/services/\``,
244
+ },
245
+ {
246
+ path: 'README.md',
247
+ template: `# {{projectName}}
248
+
249
+ {{projectDescription}}
250
+
251
+ ## Getting Started
252
+
253
+ \`\`\`bash
254
+ npm install
255
+ npm run dev
256
+ \`\`\`
257
+
258
+ ## Scripts
259
+
260
+ - \`npm run dev\` - Start development server
261
+ - \`npm run build\` - Build for production
262
+ - \`npm run preview\` - Preview production build
263
+ - \`npm run test\` - Run tests
264
+ - \`npm run lint\` - Lint code`,
265
+ },
266
+ ],
267
+ postCreate: [
268
+ {
269
+ command: 'npm install',
270
+ description: 'Installing dependencies',
271
+ },
272
+ ],
273
+ recommendedSkills: ['test', 'build', 'dev'],
274
+ };
275
+ //# sourceMappingURL=react-typescript.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"react-typescript.js","sourceRoot":"","sources":["../../../src/scaffold/templates/react-typescript.ts"],"names":[],"mappings":";;;AAEa,QAAA,uBAAuB,GAAkB;IACpD,EAAE,EAAE,kBAAkB;IACtB,IAAI,EAAE,oBAAoB;IAC1B,WAAW,EAAE,4DAA4D;IACzE,IAAI,EAAE,UAAU;IAChB,IAAI,EAAE,IAAI;IACV,IAAI,EAAE,CAAC,OAAO,EAAE,YAAY,EAAE,MAAM,EAAE,UAAU,CAAC;IACjD,KAAK,EAAE;QACL;YACE,IAAI,EAAE,cAAc;YACpB,QAAQ,EAAE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EA8Bd;SACG;QACD;YACE,IAAI,EAAE,eAAe;YACrB,QAAQ,EAAE;;;;;;;;;;;;;;;;;;;;EAoBd;SACG;QACD;YACE,IAAI,EAAE,gBAAgB;YACtB,QAAQ,EAAE;;;;;GAKb;SACE;QACD;YACE,IAAI,EAAE,YAAY;YAClB,QAAQ,EAAE;;;;;;;;;;;;QAYR;SACH;QACD;YACE,IAAI,EAAE,cAAc;YACpB,QAAQ,EAAE;;;;;;;;;EASd;SACG;QACD;YACE,IAAI,EAAE,aAAa;YACnB,QAAQ,EAAE;;;;;;;;;;;;;;;;;;;mBAmBG;SACd;QACD;YACE,IAAI,EAAE,aAAa;YACnB,QAAQ,EAAE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EA+Bd;SACG;QACD;YACE,IAAI,EAAE,eAAe;YACrB,QAAQ,EAAE;;;;;;;;;;;;;;;;;EAiBd;SACG;QACD;YACE,IAAI,EAAE,mBAAmB;YACzB,QAAQ,EAAE,uCAAuC;SAClD;QACD;YACE,IAAI,EAAE,YAAY;YAClB,QAAQ,EAAE;;;;;;;;;;;;;;;;;;UAkBN;SACL;QACD;YACE,IAAI,EAAE,WAAW;YACjB,QAAQ,EAAE;;;;;;;;;;;;;;;;;;;;;;;;;;;;6CA4B6B;SACxC;QACD;YACE,IAAI,EAAE,WAAW;YACjB,QAAQ,EAAE;;;;;;;;;;;;;;;;;+BAiBe;SAC1B;KACF;IACD,UAAU,EAAE;QACV;YACE,OAAO,EAAE,aAAa;YACtB,WAAW,EAAE,yBAAyB;SACvC;KACF;IACD,iBAAiB,EAAE,CAAC,MAAM,EAAE,OAAO,EAAE,KAAK,CAAC;CAC5C,CAAC"}