@idealyst/cli 1.0.82 โ 1.0.84
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.
- package/dist/templates/shared/src/components/HelloWorld.tsx +38 -38
- package/dist/templates/shared/src/navigation/AppRouter.tsx +7 -7
- package/dist/templates/web/src/components/TestDemo.tsx +21 -21
- package/package.json +1 -1
- package/templates/shared/src/components/HelloWorld.tsx +40 -40
- package/templates/shared/src/navigation/AppRouter.tsx +10 -10
- package/templates/web/README.md +0 -16
- package/templates/web/package.json +1 -1
- package/templates/web/src/components/TestDemo.tsx +21 -21
- package/templates/web/vite.config.ts +3 -2
- package/templates/workspace/.devcontainer/devcontainer.json +1 -0
- package/docs/LLM-CLI-QUICK-REFERENCE.md +0 -123
- package/docs/LLM-CLI-REFERENCE.md +0 -514
|
@@ -6,17 +6,17 @@ import { HelloWorld } from '../components/HelloWorld';
|
|
|
6
6
|
const HomeScreen = () => (
|
|
7
7
|
<Screen>
|
|
8
8
|
<View spacing="lg">
|
|
9
|
-
<Text size="
|
|
10
|
-
<Text size="
|
|
9
|
+
<Text size="xl" weight="bold">Home</Text>
|
|
10
|
+
<Text size="md">Welcome to your {{projectName}} app!</Text>
|
|
11
11
|
<View spacing="md" style={{ marginTop: 24 }}>
|
|
12
|
-
<Text size="
|
|
12
|
+
<Text size="sm">
|
|
13
13
|
This app uses tab navigation. Navigate between tabs using the bottom bar on mobile or the top tabs on web.
|
|
14
14
|
</Text>
|
|
15
15
|
</View>
|
|
16
16
|
|
|
17
17
|
{/* API Testing Component */}
|
|
18
18
|
<View spacing="md" style={{ marginTop: 32 }}>
|
|
19
|
-
<Text size="
|
|
19
|
+
<Text size="md" weight="semibold">API Test</Text>
|
|
20
20
|
<HelloWorld name="{{projectName}}" />
|
|
21
21
|
</View>
|
|
22
22
|
</View>
|
|
@@ -26,10 +26,10 @@ const HomeScreen = () => (
|
|
|
26
26
|
const ProfileScreen = () => (
|
|
27
27
|
<Screen>
|
|
28
28
|
<View spacing="lg">
|
|
29
|
-
<Text size="
|
|
30
|
-
<Text size="
|
|
29
|
+
<Text size="xl" weight="bold">Profile</Text>
|
|
30
|
+
<Text size="md">User profile and account settings</Text>
|
|
31
31
|
<View spacing="md" style={{ marginTop: 24 }}>
|
|
32
|
-
<Text size="
|
|
32
|
+
<Text size="sm">
|
|
33
33
|
Manage your account details and preferences here.
|
|
34
34
|
</Text>
|
|
35
35
|
</View>
|
|
@@ -40,10 +40,10 @@ const ProfileScreen = () => (
|
|
|
40
40
|
const SettingsScreen = () => (
|
|
41
41
|
<Screen>
|
|
42
42
|
<View spacing="lg">
|
|
43
|
-
<Text size="
|
|
44
|
-
<Text size="
|
|
43
|
+
<Text size="xl" weight="bold">Settings</Text>
|
|
44
|
+
<Text size="md">App configuration and preferences</Text>
|
|
45
45
|
<View spacing="md" style={{ marginTop: 24 }}>
|
|
46
|
-
<Text size="
|
|
46
|
+
<Text size="sm">
|
|
47
47
|
Customize your app experience with various settings and options.
|
|
48
48
|
</Text>
|
|
49
49
|
</View>
|
package/templates/web/README.md
CHANGED
|
@@ -122,22 +122,6 @@ The app uses the Idealyst Framework for consistent UI and navigation that works
|
|
|
122
122
|
|
|
123
123
|
Edit `src/App.tsx` to start building your application.
|
|
124
124
|
|
|
125
|
-
### Styling
|
|
126
|
-
|
|
127
|
-
The app uses Unistyles for cross-platform styling. You can create styles that work on both web and mobile:
|
|
128
|
-
|
|
129
|
-
```tsx
|
|
130
|
-
import { createStyleSheet } from 'react-native-unistyles';
|
|
131
|
-
|
|
132
|
-
const styles = createStyleSheet({
|
|
133
|
-
container: {
|
|
134
|
-
flex: 1,
|
|
135
|
-
justifyContent: 'center',
|
|
136
|
-
alignItems: 'center'
|
|
137
|
-
}
|
|
138
|
-
});
|
|
139
|
-
```
|
|
140
|
-
|
|
141
125
|
### Learn More
|
|
142
126
|
|
|
143
127
|
- [Idealyst Framework Documentation](https://github.com/your-username/idealyst-framework)
|
|
@@ -30,7 +30,7 @@
|
|
|
30
30
|
"react-dom": "^19.1.0",
|
|
31
31
|
"react-native": "^0.80.1",
|
|
32
32
|
"react-native-edge-to-edge": "^1.6.2",
|
|
33
|
-
"react-native-nitro-modules": "0.
|
|
33
|
+
"react-native-nitro-modules": "0.30.0",
|
|
34
34
|
"react-native-unistyles": "^3.0.10",
|
|
35
35
|
"react-native-web": "^0.20.0",
|
|
36
36
|
"react-router": "^7.6.3",
|
|
@@ -37,8 +37,8 @@ export const TestDemo: React.FC = () => {
|
|
|
37
37
|
|
|
38
38
|
if (isLoading) {
|
|
39
39
|
return (
|
|
40
|
-
<Card variant="outlined" padding="
|
|
41
|
-
<Text size="
|
|
40
|
+
<Card variant="outlined" padding="lg">
|
|
41
|
+
<Text size="md">Loading tests...</Text>
|
|
42
42
|
</Card>
|
|
43
43
|
);
|
|
44
44
|
}
|
|
@@ -46,21 +46,21 @@ export const TestDemo: React.FC = () => {
|
|
|
46
46
|
return (
|
|
47
47
|
<View style={{ gap: 16 }}>
|
|
48
48
|
{/* Header */}
|
|
49
|
-
<Card variant="elevated" padding="
|
|
49
|
+
<Card variant="elevated" padding="lg" intent="primary">
|
|
50
50
|
<View style={{ alignItems: 'center' }}>
|
|
51
51
|
<Text style={{ fontSize: 24, marginBottom: 8 }}>๐งช</Text>
|
|
52
|
-
<Text size="
|
|
52
|
+
<Text size="lg" weight="bold" style={{ marginBottom: 8, textAlign: 'center' }}>
|
|
53
53
|
tRPC + Database Test
|
|
54
54
|
</Text>
|
|
55
|
-
<Text size="
|
|
55
|
+
<Text size="md" style={{ textAlign: 'center' }}>
|
|
56
56
|
This demonstrates end-to-end type-safe API calls from the web app to the database.
|
|
57
57
|
</Text>
|
|
58
58
|
</View>
|
|
59
59
|
</Card>
|
|
60
60
|
|
|
61
61
|
{/* Create Test Form */}
|
|
62
|
-
<Card variant="outlined" padding="
|
|
63
|
-
<Text size="
|
|
62
|
+
<Card variant="outlined" padding="lg">
|
|
63
|
+
<Text size="md" weight="bold" style={{ marginBottom: 16 }}>
|
|
64
64
|
Create New Test
|
|
65
65
|
</Text>
|
|
66
66
|
|
|
@@ -90,15 +90,15 @@ export const TestDemo: React.FC = () => {
|
|
|
90
90
|
</Card>
|
|
91
91
|
|
|
92
92
|
{/* Test Results */}
|
|
93
|
-
<Card variant="outlined" padding="
|
|
94
|
-
<Text size="
|
|
93
|
+
<Card variant="outlined" padding="lg">
|
|
94
|
+
<Text size="md" weight="bold" style={{ marginBottom: 16 }}>
|
|
95
95
|
Test Entries ({tests?.count || 0})
|
|
96
96
|
</Text>
|
|
97
97
|
|
|
98
98
|
{tests?.data && tests.data.length > 0 ? (
|
|
99
99
|
<View style={{ gap: 12 }}>
|
|
100
100
|
{tests.data.map((test) => (
|
|
101
|
-
<Card key={test.id} variant="filled" padding="
|
|
101
|
+
<Card key={test.id} variant="filled" padding="md">
|
|
102
102
|
<View style={{
|
|
103
103
|
flexDirection: 'row',
|
|
104
104
|
justifyContent: 'space-between',
|
|
@@ -106,23 +106,23 @@ export const TestDemo: React.FC = () => {
|
|
|
106
106
|
gap: 12
|
|
107
107
|
}}>
|
|
108
108
|
<View style={{ flex: 1 }}>
|
|
109
|
-
<Text size="
|
|
109
|
+
<Text size="md" weight="semibold" style={{ marginBottom: 4 }}>
|
|
110
110
|
{test.name}
|
|
111
111
|
</Text>
|
|
112
|
-
<Text size="
|
|
112
|
+
<Text size="sm" style={{ marginBottom: 8, opacity: 0.8 }}>
|
|
113
113
|
{test.message}
|
|
114
114
|
</Text>
|
|
115
115
|
<View style={{ flexDirection: 'row', alignItems: 'center', gap: 8 }}>
|
|
116
116
|
<Card
|
|
117
117
|
variant="filled"
|
|
118
|
-
padding="
|
|
118
|
+
padding="sm"
|
|
119
119
|
intent={test.status === 'active' ? 'success' : 'neutral'}
|
|
120
120
|
>
|
|
121
|
-
<Text size="
|
|
121
|
+
<Text size="sm" weight="semibold">
|
|
122
122
|
{test.status}
|
|
123
123
|
</Text>
|
|
124
124
|
</Card>
|
|
125
|
-
<Text size="
|
|
125
|
+
<Text size="sm" style={{ opacity: 0.6 }}>
|
|
126
126
|
{new Date(test.createdAt).toLocaleDateString()}
|
|
127
127
|
</Text>
|
|
128
128
|
</View>
|
|
@@ -130,7 +130,7 @@ export const TestDemo: React.FC = () => {
|
|
|
130
130
|
<Button
|
|
131
131
|
variant="outlined"
|
|
132
132
|
intent="error"
|
|
133
|
-
size="
|
|
133
|
+
size="sm"
|
|
134
134
|
onPress={() => handleDeleteTest(test.id)}
|
|
135
135
|
disabled={deleteTestMutation.isPending}
|
|
136
136
|
>
|
|
@@ -141,8 +141,8 @@ export const TestDemo: React.FC = () => {
|
|
|
141
141
|
))}
|
|
142
142
|
</View>
|
|
143
143
|
) : (
|
|
144
|
-
<Card variant="filled" padding="
|
|
145
|
-
<Text size="
|
|
144
|
+
<Card variant="filled" padding="md" style={{ opacity: 0.6 }}>
|
|
145
|
+
<Text size="sm" style={{ textAlign: 'center' }}>
|
|
146
146
|
No tests found. Create one above to get started!
|
|
147
147
|
</Text>
|
|
148
148
|
</Card>
|
|
@@ -150,11 +150,11 @@ export const TestDemo: React.FC = () => {
|
|
|
150
150
|
</Card>
|
|
151
151
|
|
|
152
152
|
{/* Type Safety Info */}
|
|
153
|
-
<Card variant="filled" intent="success" padding="
|
|
154
|
-
<Text size="
|
|
153
|
+
<Card variant="filled" intent="success" padding="md">
|
|
154
|
+
<Text size="sm" weight="semibold" style={{ marginBottom: 4 }}>
|
|
155
155
|
โจ Type Safety Features:
|
|
156
156
|
</Text>
|
|
157
|
-
<Text size="
|
|
157
|
+
<Text size="sm">
|
|
158
158
|
โข Full TypeScript types from database to frontend โข tRPC ensures API type safety โข
|
|
159
159
|
Prisma provides database schema validation โข Real-time type checking across the stack
|
|
160
160
|
</Text>
|
|
@@ -7,8 +7,9 @@ import path from 'path'
|
|
|
7
7
|
export default defineConfig({
|
|
8
8
|
plugins: [
|
|
9
9
|
babel({
|
|
10
|
-
filter: (id) =>
|
|
11
|
-
|
|
10
|
+
filter: (id) =>
|
|
11
|
+
id.includes("node_modules/@idealyst/") ||
|
|
12
|
+
(id.includes("/packages/") && /\.(tsx?|jsx?)$/.test(id)), babelConfig: {
|
|
12
13
|
presets: [
|
|
13
14
|
['@babel/preset-typescript', {
|
|
14
15
|
isTSX: true,
|
|
@@ -1,123 +0,0 @@
|
|
|
1
|
-
# Idealyst Framework CLI - Quick LLM Command Reference
|
|
2
|
-
|
|
3
|
-
โ ๏ธ **LLM CRITICAL**: Always provide ALL arguments to prevent interactive prompts that hang automation!
|
|
4
|
-
|
|
5
|
-
## ๐จ Commands That Will Hang LLMs
|
|
6
|
-
```bash
|
|
7
|
-
# โ These will hang waiting for user input:
|
|
8
|
-
idealyst init # Missing workspace name
|
|
9
|
-
idealyst create my-app # Missing --type
|
|
10
|
-
idealyst create my-app --type native # Missing --app-name
|
|
11
|
-
idealyst create my-app --type web # Missing tRPC choice
|
|
12
|
-
idealyst create my-app --type native --app-name "App" # Missing tRPC choice
|
|
13
|
-
```
|
|
14
|
-
|
|
15
|
-
## โ
LLM-Safe Command Templates
|
|
16
|
-
```bash
|
|
17
|
-
# Always use these exact patterns:
|
|
18
|
-
idealyst init <workspace-name>
|
|
19
|
-
idealyst create <name> --type database
|
|
20
|
-
idealyst create <name> --type api
|
|
21
|
-
idealyst create <name> --type shared
|
|
22
|
-
idealyst create <name> --type native --app-name "Display Name" --with-trpc
|
|
23
|
-
idealyst create <name> --type native --app-name "Display Name" --no-trpc
|
|
24
|
-
idealyst create <name> --type web --with-trpc
|
|
25
|
-
idealyst create <name> --type web --no-trpc
|
|
26
|
-
```
|
|
27
|
-
|
|
28
|
-
## Essential Commands
|
|
29
|
-
|
|
30
|
-
### Initialize Workspace (Required First)
|
|
31
|
-
```bash
|
|
32
|
-
# โ
Always provide workspace name
|
|
33
|
-
idealyst init <workspace-name>
|
|
34
|
-
cd <workspace-name>
|
|
35
|
-
|
|
36
|
-
# โ Never run without name (will prompt)
|
|
37
|
-
# idealyst init
|
|
38
|
-
```
|
|
39
|
-
|
|
40
|
-
### Create Projects (Run from workspace directory)
|
|
41
|
-
```bash
|
|
42
|
-
# Database layer (Prisma + Zod) - No prompts
|
|
43
|
-
idealyst create <name> --type database
|
|
44
|
-
|
|
45
|
-
# API server (tRPC + Express) - No prompts
|
|
46
|
-
idealyst create <name> --type api
|
|
47
|
-
|
|
48
|
-
# React Native mobile app - REQUIRES app-name and trpc preference
|
|
49
|
-
idealyst create <name> --type native --app-name "Display Name" --with-trpc
|
|
50
|
-
idealyst create <name> --type native --app-name "Display Name" --no-trpc
|
|
51
|
-
|
|
52
|
-
# React web app (Vite) - REQUIRES trpc preference
|
|
53
|
-
idealyst create <name> --type web --with-trpc
|
|
54
|
-
idealyst create <name> --type web --no-trpc
|
|
55
|
-
|
|
56
|
-
# Shared TypeScript library - No prompts
|
|
57
|
-
idealyst create <name> --type shared
|
|
58
|
-
```
|
|
59
|
-
|
|
60
|
-
## Project Types & Purposes
|
|
61
|
-
|
|
62
|
-
| Type | Purpose | Key Technologies | Exports |
|
|
63
|
-
|------|---------|------------------|---------|
|
|
64
|
-
| `database` | Data layer | Prisma, Zod, TypeScript | `{ db, schemas, PrismaClient, types }` |
|
|
65
|
-
| `api` | Backend server | tRPC, Express, Zod | tRPC router, middleware |
|
|
66
|
-
| `native` | Mobile app | React Native, TypeScript | Mobile application |
|
|
67
|
-
| `web` | Web app | React, Vite, TypeScript | Web application |
|
|
68
|
-
| `shared` | Utilities | TypeScript, Rollup | Reusable functions/types |
|
|
69
|
-
|
|
70
|
-
## Architecture Patterns
|
|
71
|
-
|
|
72
|
-
### Full-Stack App (Recommended)
|
|
73
|
-
```bash
|
|
74
|
-
# โ
LLM-Safe: All arguments provided
|
|
75
|
-
idealyst init my-app && cd my-app
|
|
76
|
-
idealyst create database --type database
|
|
77
|
-
idealyst create api --type api
|
|
78
|
-
idealyst create mobile --type native --app-name "Mobile App" --with-trpc
|
|
79
|
-
idealyst create web --type web --with-trpc
|
|
80
|
-
```
|
|
81
|
-
|
|
82
|
-
### Database Integration
|
|
83
|
-
```typescript
|
|
84
|
-
// In API server
|
|
85
|
-
import { db } from '@workspace/database';
|
|
86
|
-
const users = await db.user.findMany();
|
|
87
|
-
|
|
88
|
-
// In clients (with tRPC)
|
|
89
|
-
const { data } = await api.users.getAll.useQuery();
|
|
90
|
-
```
|
|
91
|
-
|
|
92
|
-
## Key Rules for LLMs
|
|
93
|
-
1. **Always provide workspace name** - `idealyst init my-project` (never just `idealyst init`)
|
|
94
|
-
2. **Always provide project name AND --type** - `idealyst create api --type api`
|
|
95
|
-
3. **For native: Always provide --app-name AND tRPC choice** - `--app-name "App Name" --with-trpc`
|
|
96
|
-
4. **For web: Always provide tRPC choice** - `--with-trpc` or `--no-trpc`
|
|
97
|
-
5. **Use --skip-install** - For faster testing/iteration
|
|
98
|
-
6. **Use descriptive names** - `user-database`, `product-api`, not `db`, `api`
|
|
99
|
-
|
|
100
|
-
## Common Patterns
|
|
101
|
-
```bash
|
|
102
|
-
# E-commerce (full arguments)
|
|
103
|
-
idealyst init ecommerce-platform && cd ecommerce-platform
|
|
104
|
-
idealyst create product-database --type database
|
|
105
|
-
idealyst create api --type api
|
|
106
|
-
idealyst create customer-mobile --type native --app-name "Customer App" --with-trpc
|
|
107
|
-
idealyst create admin-web --type web --with-trpc
|
|
108
|
-
|
|
109
|
-
# SaaS (full arguments)
|
|
110
|
-
idealyst init saas-app && cd saas-app
|
|
111
|
-
idealyst create user-database --type database
|
|
112
|
-
idealyst create auth-api --type api
|
|
113
|
-
idealyst create main-api --type api
|
|
114
|
-
idealyst create dashboard --type web --with-trpc
|
|
115
|
-
idealyst create mobile --type native --app-name "SaaS Mobile" --with-trpc
|
|
116
|
-
|
|
117
|
-
# Content platform (full arguments)
|
|
118
|
-
idealyst init content-platform && cd content-platform
|
|
119
|
-
idealyst create content-database --type database
|
|
120
|
-
idealyst create cms-api --type api
|
|
121
|
-
idealyst create public-web --type web --no-trpc
|
|
122
|
-
idealyst create admin-web --type web --with-trpc
|
|
123
|
-
```
|