create-ern-boilerplate 0.0.30 ā 0.0.31
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/README.md +185 -72
- package/create.js +40 -23
- package/package.json +1 -1
- package/templates/advanced/package.json +4 -13
- package/templates/agent-generator/AI_GUIDE.md +319 -0
- package/templates/agent-generator/CONVENTIONS.md +339 -0
- package/templates/agent-generator/GENERATE_RULES.md +343 -0
- package/templates/agent-generator/README.md +288 -0
- package/templates/agent-generator/ai-context.json +14 -0
- package/templates/agent-generator/app/(auth)/_layout.tsx +17 -0
- package/templates/agent-generator/app/(auth)/login.tsx +89 -0
- package/templates/agent-generator/app/(auth)/register.tsx +102 -0
- package/templates/agent-generator/app/(tabs)/_layout.tsx +47 -0
- package/templates/agent-generator/app/(tabs)/index.tsx +46 -0
- package/templates/agent-generator/app/(tabs)/settings.tsx +71 -0
- package/templates/agent-generator/app/_layout.tsx +27 -0
- package/templates/agent-generator/app.json +58 -0
- package/templates/agent-generator/app.prod.json +60 -0
- package/templates/agent-generator/app.staging.json +60 -0
- package/templates/agent-generator/babel.config.js +29 -0
- package/templates/agent-generator/eas.json +42 -0
- package/templates/agent-generator/examples/component.example.tsx +91 -0
- package/templates/agent-generator/examples/hook.example.ts +133 -0
- package/templates/agent-generator/examples/screen.example.tsx +138 -0
- package/templates/agent-generator/examples/service.example.ts +152 -0
- package/templates/agent-generator/global.css +3 -0
- package/templates/agent-generator/metro.config.js +9 -0
- package/templates/agent-generator/nativewind-env.d.ts +3 -0
- package/templates/agent-generator/package.json +94 -0
- package/templates/agent-generator/server/db.json +0 -0
- package/templates/agent-generator/src/assets/images/adaptive-icon.png +0 -0
- package/templates/agent-generator/src/assets/images/favicon.png +0 -0
- package/templates/agent-generator/src/assets/images/icon.png +0 -0
- package/templates/agent-generator/src/assets/images/splash-icon.png +0 -0
- package/templates/agent-generator/src/components/auth/ProtectedRoute.tsx +105 -0
- package/templates/agent-generator/src/components/common/Button.tsx +70 -0
- package/templates/agent-generator/src/components/common/Card.tsx +32 -0
- package/templates/agent-generator/src/components/common/Input.tsx +75 -0
- package/templates/agent-generator/src/components/common/Loading.tsx +41 -0
- package/templates/agent-generator/src/components/config/ToastConfig.tsx +109 -0
- package/templates/agent-generator/src/components/shared/ConfirmDialog.tsx +151 -0
- package/templates/agent-generator/src/components/shared/FormInput.tsx +67 -0
- package/templates/agent-generator/src/components/shared/LucideIcon.tsx +18 -0
- package/templates/agent-generator/src/components/shared/RoleSelector.tsx +63 -0
- package/templates/agent-generator/src/hooks/useAuth.ts +12 -0
- package/templates/agent-generator/src/hooks/useTheme.ts +12 -0
- package/templates/agent-generator/src/services/api.ts +97 -0
- package/templates/agent-generator/src/services/authService.ts +45 -0
- package/templates/agent-generator/src/services/mockApi/auth.mock.ts +89 -0
- package/templates/agent-generator/src/services/mockApi/categories.mock.ts +75 -0
- package/templates/agent-generator/src/services/mockApi/index.ts +79 -0
- package/templates/agent-generator/src/services/mockApi/products.mock.ts +125 -0
- package/templates/agent-generator/src/services/mockApi/users.mock.ts +83 -0
- package/templates/agent-generator/src/store/authStore.ts +45 -0
- package/templates/agent-generator/src/store/themeStore.ts +20 -0
- package/templates/agent-generator/src/theme/colors.ts +32 -0
- package/templates/agent-generator/src/types/api.types.ts +28 -0
- package/templates/agent-generator/src/types/auth.types.ts +38 -0
- package/templates/agent-generator/src/types/product.types.ts +49 -0
- package/templates/agent-generator/src/types/user.types.ts +40 -0
- package/templates/agent-generator/src/utils/constants.ts +48 -0
- package/templates/agent-generator/src/utils/storage.ts +73 -0
- package/templates/agent-generator/src/utils/validation.ts +54 -0
- package/templates/agent-generator/tailwind.config.js +33 -0
- package/templates/agent-generator/tsconfig.json +35 -0
- package/templates/simple/.claude/settings.local.json +11 -0
- package/templates/simple/.clinerules +446 -0
- package/templates/simple/.env.example +44 -0
- package/templates/simple/.prettierrc +13 -0
- package/templates/simple/AI_DEVELOPMENT_GUIDE.md +709 -0
- package/templates/simple/AI_QUICK_START.md +245 -0
- package/templates/simple/ARCHITECTURE.md +754 -0
- package/templates/simple/CHANGELOG.md +313 -0
- package/templates/simple/COMPONENT_TEMPLATES.md +761 -0
- package/templates/simple/EXAMPLES.md +1132 -0
- package/templates/simple/IMPROVEMENTS_SUMMARY.md +399 -0
- package/templates/simple/PROJECT_CONTEXT.md +399 -0
- package/templates/simple/README.md +438 -0
- package/templates/simple/app/(admin)/_layout.tsx +51 -0
- package/templates/simple/app/(admin)/profile.tsx +589 -0
- package/templates/simple/app/(admin)/user-management.tsx +604 -0
- package/templates/simple/app/(auth)/_layout.tsx +25 -0
- package/templates/simple/app/(auth)/login.tsx +782 -0
- package/templates/simple/app/(auth)/register.tsx +547 -0
- package/templates/simple/app/(protected)/_layout.tsx +91 -0
- package/templates/simple/app/(protected)/home.tsx +665 -0
- package/templates/simple/app/(protected)/settings.tsx +332 -0
- package/templates/simple/app/README.md +439 -0
- package/templates/simple/app/_SCREEN_TEMPLATE.tsx +311 -0
- package/templates/simple/app/_layout.tsx +24 -0
- package/templates/simple/app.json +58 -0
- package/templates/simple/app.prod.json +60 -0
- package/templates/simple/app.staging.json +60 -0
- package/templates/simple/babel.config.js +29 -0
- package/templates/simple/eas.json +42 -0
- package/templates/simple/global.css +3 -0
- package/templates/simple/metro.config.js +9 -0
- package/templates/simple/nativewind-env.d.ts +3 -0
- package/templates/simple/package.json +101 -0
- package/templates/simple/server/db.json +78 -0
- package/templates/simple/setup.sh +158 -0
- package/templates/simple/src/assets/images/adaptive-icon.png +0 -0
- package/templates/simple/src/assets/images/favicon.png +0 -0
- package/templates/simple/src/assets/images/icon.png +0 -0
- package/templates/simple/src/assets/images/splash-icon.png +0 -0
- package/templates/simple/src/components/auth/ProtectedRoute.tsx +105 -0
- package/templates/simple/src/components/common/Button.tsx +70 -0
- package/templates/simple/src/components/common/Card.tsx +32 -0
- package/templates/simple/src/components/common/ErrorBoundary.tsx +167 -0
- package/templates/simple/src/components/common/Input.tsx +75 -0
- package/templates/simple/src/components/common/Loading.tsx +41 -0
- package/templates/simple/src/components/config/ToastConfig.tsx +109 -0
- package/templates/simple/src/components/header/AppHeader.tsx +160 -0
- package/templates/simple/src/components/shared/ConfirmDialog.tsx +151 -0
- package/templates/simple/src/components/shared/FormInput.tsx +67 -0
- package/templates/simple/src/components/shared/LucideIcon.tsx +18 -0
- package/templates/simple/src/components/shared/RoleSelector.tsx +63 -0
- package/templates/simple/src/components/users/EmptyState.tsx +70 -0
- package/templates/simple/src/components/users/ErrorState.tsx +64 -0
- package/templates/simple/src/components/users/FilterModal.tsx +264 -0
- package/templates/simple/src/components/users/UserCard.tsx +230 -0
- package/templates/simple/src/components/users/UserFormModal.tsx +230 -0
- package/templates/simple/src/contexts/AuthContext.tsx +93 -0
- package/templates/simple/src/contexts/ThemeContext.tsx +56 -0
- package/templates/simple/src/hooks/useAuth.ts +12 -0
- package/templates/simple/src/hooks/useTheme.ts +12 -0
- package/templates/simple/src/hooks/useUsers.ts +261 -0
- package/templates/simple/src/services/api.ts +97 -0
- package/templates/simple/src/services/authService.ts +45 -0
- package/templates/simple/src/services/mockApi/auth.mock.ts +89 -0
- package/templates/simple/src/services/mockApi/categories.mock.ts +75 -0
- package/templates/simple/src/services/mockApi/index.ts +79 -0
- package/templates/simple/src/services/mockApi/products.mock.ts +125 -0
- package/templates/simple/src/services/mockApi/users.mock.ts +83 -0
- package/templates/simple/src/services/productService.ts +143 -0
- package/templates/simple/src/services/userService.ts +49 -0
- package/templates/simple/src/theme/colors.ts +32 -0
- package/templates/simple/src/types/api.types.ts +28 -0
- package/templates/simple/src/types/auth.types.ts +42 -0
- package/templates/simple/src/types/product.types.ts +49 -0
- package/templates/simple/src/types/user.types.ts +40 -0
- package/templates/simple/src/utils/constants.ts +48 -0
- package/templates/simple/src/utils/routes.ts +75 -0
- package/templates/simple/src/utils/storage.ts +73 -0
- package/templates/simple/src/utils/validation.ts +54 -0
- package/templates/simple/tailwind.config.js +33 -0
- package/templates/simple/tsconfig.json +35 -0
package/README.md
CHANGED
|
@@ -1,51 +1,69 @@
|
|
|
1
1
|
# š create-ern-boilerplate
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
**Generator boilerplate Expo React Native yang powerful dan mudah digunakan!**
|
|
4
4
|
|
|
5
|
-
|
|
5
|
+
Buat proyek **React Native Expo** production-ready dalam hitungan detik dengan berbagai template siap pakai. Tidak perlu instalasi, langsung pakai dengan **npx**!
|
|
6
6
|
|
|
7
7
|
---
|
|
8
8
|
|
|
9
|
-
##
|
|
9
|
+
## ⨠Apa itu create-ern-boilerplate?
|
|
10
10
|
|
|
11
|
-
|
|
12
|
-
|
|
11
|
+
`create-ern-boilerplate` adalah CLI tool yang membantu kamu membuat project Expo React Native dengan cepat menggunakan template yang sudah dikonfigurasi dengan baik.
|
|
12
|
+
|
|
13
|
+
ā
**Tidak perlu instalasi global** - langsung pakai dengan npx
|
|
14
|
+
ā
**Mode interaktif** - pilih template dan konfigurasi dengan mudah
|
|
15
|
+
ā
**Mode cepat** - buat project dalam satu baris perintah
|
|
16
|
+
ā
**Berbagai template** - minimal, redux, dan lainnya
|
|
17
|
+
ā
**Auto setup** - nama project, bundle identifier, dan dependencies otomatis terkonfigurasi
|
|
18
|
+
|
|
19
|
+
---
|
|
20
|
+
|
|
21
|
+
## š Quick Start
|
|
22
|
+
|
|
23
|
+
Cara tercepat untuk membuat project baru:
|
|
13
24
|
|
|
14
25
|
```bash
|
|
15
|
-
npx create-ern-boilerplate
|
|
26
|
+
npx create-ern-boilerplate my-app -y
|
|
16
27
|
```
|
|
17
28
|
|
|
18
|
-
|
|
29
|
+
Atau gunakan alias yang lebih pendek:
|
|
30
|
+
|
|
31
|
+
```bash
|
|
32
|
+
npx ern-boilerplate my-app -y
|
|
33
|
+
```
|
|
19
34
|
|
|
20
|
-
|
|
35
|
+
Selesai! Project kamu sudah siap dengan template default dan dependencies sudah terinstall.
|
|
21
36
|
|
|
22
|
-
### š¢
|
|
37
|
+
### š¢ Mode Interaktif (Direkomendasikan untuk pemula)
|
|
23
38
|
|
|
24
|
-
Jalankan tanpa argumen
|
|
39
|
+
Jalankan tanpa argumen untuk memilih konfigurasi secara interaktif:
|
|
25
40
|
|
|
26
41
|
```bash
|
|
27
42
|
npx create-ern-boilerplate
|
|
28
43
|
```
|
|
29
44
|
|
|
30
45
|
Kamu akan ditanya:
|
|
46
|
+
- āļø Nama project
|
|
47
|
+
- š Deskripsi project
|
|
48
|
+
- šØ Template yang ingin digunakan
|
|
49
|
+
- āļø Apakah ingin langsung install dependencies
|
|
31
50
|
|
|
32
|
-
|
|
33
|
-
- Deskripsi
|
|
34
|
-
- Template yang ingin digunakan
|
|
35
|
-
- Apakah ingin langsung install dependencies
|
|
36
|
-
|
|
37
|
-
**Contoh:**
|
|
51
|
+
**Contoh interaksi:**
|
|
38
52
|
|
|
39
53
|
```
|
|
40
54
|
? Nama project kamu: my-expo-app
|
|
41
55
|
? Deskripsi singkat: Aplikasi keren dengan Expo
|
|
42
56
|
? Pilih template: redux
|
|
43
57
|
? Langsung install dependencies setelah membuat project? Yes
|
|
58
|
+
|
|
59
|
+
⨠Membuat project my-expo-app...
|
|
60
|
+
š¦ Menginstall dependencies...
|
|
61
|
+
ā
Project berhasil dibuat!
|
|
44
62
|
```
|
|
45
63
|
|
|
46
64
|
---
|
|
47
65
|
|
|
48
|
-
### š”
|
|
66
|
+
### š” Mode Cepat (Direkomendasikan untuk yang sudah familiar)
|
|
49
67
|
|
|
50
68
|
Langsung buat project baru tanpa pertanyaan:
|
|
51
69
|
|
|
@@ -53,119 +71,214 @@ Langsung buat project baru tanpa pertanyaan:
|
|
|
53
71
|
npx create-ern-boilerplate my-app -y
|
|
54
72
|
```
|
|
55
73
|
|
|
56
|
-
|
|
57
|
-
|
|
74
|
+
Atau dengan alias pendek:
|
|
75
|
+
|
|
76
|
+
```bash
|
|
77
|
+
npx ern-boilerplate my-app -y
|
|
78
|
+
```
|
|
79
|
+
|
|
80
|
+
Hasilnya:
|
|
81
|
+
- ā
Otomatis pakai **template default (`minimal`)**
|
|
82
|
+
- ā
Dependencies langsung terinstall
|
|
83
|
+
- ā
Siap untuk development
|
|
58
84
|
|
|
59
85
|
---
|
|
60
86
|
|
|
61
|
-
### šµ
|
|
87
|
+
### šµ Mode Kustom (Full control)
|
|
62
88
|
|
|
63
|
-
|
|
89
|
+
Tentukan semua konfigurasi langsung di command line:
|
|
64
90
|
|
|
65
91
|
```bash
|
|
66
92
|
npx create-ern-boilerplate my-app -y --desc "Boilerplate lengkap" --template redux
|
|
67
93
|
```
|
|
68
94
|
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
95
|
+
Atau dengan alias:
|
|
96
|
+
|
|
97
|
+
```bash
|
|
98
|
+
npx ern-boilerplate my-app -y --desc "Boilerplate lengkap" --template redux
|
|
99
|
+
```
|
|
100
|
+
|
|
101
|
+
Hasilnya:
|
|
102
|
+
- š Project **my-app** langsung terbuat
|
|
103
|
+
- š Deskripsi otomatis terisi
|
|
104
|
+
- š§© Menggunakan template **redux**
|
|
105
|
+
- āļø Dependencies auto install
|
|
73
106
|
|
|
74
107
|
---
|
|
75
108
|
|
|
76
109
|
## āļø Argumen & Opsi CLI
|
|
77
110
|
|
|
78
|
-
|
|
79
|
-
|------|--------|------------|--------|
|
|
80
|
-
| `-y` / `--yes` | | Jalankan mode cepat tanpa prompt | `npx create-ern-boilerplate my-app -y` |
|
|
81
|
-
| `--desc` | | Tambahkan deskripsi project | `--desc "Aplikasi keren"` |
|
|
82
|
-
| `--template` | | Pilih template tertentu | `--template redux` |
|
|
83
|
-
| `--install` | | Auto install dependencies di mode cepat | `-y --install` |
|
|
111
|
+
### Command yang tersedia:
|
|
84
112
|
|
|
85
|
-
|
|
113
|
+
```bash
|
|
114
|
+
npx create-ern-boilerplate [nama-project] [opsi]
|
|
115
|
+
# atau
|
|
116
|
+
npx ern-boilerplate [nama-project] [opsi]
|
|
117
|
+
```
|
|
86
118
|
|
|
87
|
-
|
|
119
|
+
### Opsi yang tersedia:
|
|
88
120
|
|
|
89
|
-
|
|
121
|
+
| Opsi | Deskripsi | Default | Contoh |
|
|
122
|
+
|------|-----------|---------|--------|
|
|
123
|
+
| `[nama-project]` | Nama project yang akan dibuat | Akan ditanyakan jika tidak diisi | `my-app` |
|
|
124
|
+
| `-y`, `--yes` | Mode cepat tanpa prompt | `false` | `npx create-ern-boilerplate my-app -y` |
|
|
125
|
+
| `--desc <text>` | Deskripsi project | `""` | `--desc "Aplikasi keren"` |
|
|
126
|
+
| `--template <name>` | Pilih template tertentu | `minimal` | `--template redux` |
|
|
127
|
+
| `--install` | Auto install dependencies | `true` saat `-y` | `-y --install` |
|
|
90
128
|
|
|
129
|
+
### Contoh kombinasi:
|
|
130
|
+
|
|
131
|
+
```bash
|
|
132
|
+
# Hanya nama project
|
|
133
|
+
npx create-ern-boilerplate my-app
|
|
134
|
+
|
|
135
|
+
# Mode cepat
|
|
136
|
+
npx ern-boilerplate my-app -y
|
|
137
|
+
|
|
138
|
+
# Custom template
|
|
139
|
+
npx create-ern-boilerplate my-app -y --template redux
|
|
140
|
+
|
|
141
|
+
# Full custom
|
|
142
|
+
npx ern-boilerplate my-app -y --desc "My awesome app" --template redux
|
|
91
143
|
```
|
|
92
|
-
/templates
|
|
93
|
-
āāā minimal
|
|
94
|
-
āāā redux
|
|
95
|
-
āāā default
|
|
96
|
-
āāā ...
|
|
97
|
-
```
|
|
98
144
|
|
|
99
|
-
|
|
145
|
+
---
|
|
146
|
+
|
|
147
|
+
## š§© Template yang Tersedia
|
|
148
|
+
|
|
149
|
+
Saat ini tersedia beberapa template siap pakai:
|
|
150
|
+
|
|
151
|
+
| Template | Deskripsi | Cocok untuk |
|
|
152
|
+
|----------|-----------|-------------|
|
|
153
|
+
| `minimal` | Template dasar dengan struktur minimalis | Project sederhana, prototyping cepat |
|
|
154
|
+
| `redux` | Lengkap dengan Redux state management | Aplikasi kompleks dengan state management |
|
|
155
|
+
| `default` | Template standar dengan setup umum | Kebanyakan project |
|
|
156
|
+
|
|
157
|
+
### Cara menggunakan template:
|
|
158
|
+
|
|
159
|
+
```bash
|
|
160
|
+
# Template minimal (default)
|
|
161
|
+
npx create-ern-boilerplate my-app -y
|
|
162
|
+
|
|
163
|
+
# Template redux
|
|
164
|
+
npx create-ern-boilerplate my-app -y --template redux
|
|
165
|
+
|
|
166
|
+
# Template default
|
|
167
|
+
npx create-ern-boilerplate my-app -y --template default
|
|
168
|
+
```
|
|
100
169
|
|
|
101
170
|
---
|
|
102
171
|
|
|
103
|
-
## š ļø
|
|
172
|
+
## š ļø Apa yang Terjadi di Balik Layar?
|
|
173
|
+
|
|
174
|
+
Saat kamu menjalankan `npx create-ern-boilerplate`, ini yang terjadi:
|
|
104
175
|
|
|
105
|
-
1.
|
|
106
|
-
2.
|
|
107
|
-
3.
|
|
108
|
-
4.
|
|
109
|
-
|
|
110
|
-
-
|
|
111
|
-
-
|
|
112
|
-
|
|
176
|
+
1. **š„ npx mengunduh package terbaru** - Tidak perlu install, npx otomatis download versi terbaru
|
|
177
|
+
2. **āļø CLI membaca argumen** - Memproses command dan opsi yang kamu berikan
|
|
178
|
+
3. **š¬ Mode interaktif (opsional)** - Menampilkan prompt jika kamu tidak pakai flag `-y`
|
|
179
|
+
4. **š Copy template** - Template yang dipilih disalin ke folder project baru
|
|
180
|
+
5. **āļø Auto-configure** - Update `package.json` dan `app.json` dengan:
|
|
181
|
+
- Nama project kamu
|
|
182
|
+
- Deskripsi project
|
|
183
|
+
- Bundle identifier untuk iOS & Android
|
|
184
|
+
6. **š¦ Install dependencies** - npm install otomatis dijalankan
|
|
185
|
+
7. **ā
Selesai!** - Project siap untuk development
|
|
113
186
|
|
|
114
187
|
---
|
|
115
188
|
|
|
116
|
-
##
|
|
189
|
+
## šÆ Hasil Akhir
|
|
117
190
|
|
|
118
191
|
Setelah menjalankan perintah:
|
|
119
192
|
|
|
120
193
|
```bash
|
|
121
|
-
npx create-ern-boilerplate my-expo-app -y --
|
|
194
|
+
npx create-ern-boilerplate my-expo-app -y --template redux
|
|
122
195
|
```
|
|
123
196
|
|
|
124
|
-
|
|
197
|
+
Kamu akan mendapatkan struktur project seperti ini:
|
|
125
198
|
|
|
126
199
|
```
|
|
127
200
|
my-expo-app/
|
|
128
|
-
āāā app.json
|
|
129
|
-
āāā package.json
|
|
130
|
-
āāā App.js
|
|
131
|
-
āāā src/
|
|
132
|
-
ā āāā components/
|
|
133
|
-
ā āāā screens/
|
|
134
|
-
ā āāā redux/
|
|
201
|
+
āāā š± app.json # Konfigurasi Expo
|
|
202
|
+
āāā š¦ package.json # Dependencies & scripts
|
|
203
|
+
āāā š App.js # Entry point aplikasi
|
|
204
|
+
āāā š src/
|
|
205
|
+
ā āāā components/ # React components
|
|
206
|
+
ā āāā screens/ # Screen components
|
|
207
|
+
ā āāā redux/ # Redux store & slices
|
|
135
208
|
ā āāā ...
|
|
136
209
|
āāā ...
|
|
137
210
|
```
|
|
138
211
|
|
|
139
|
-
|
|
212
|
+
### Langkah selanjutnya:
|
|
140
213
|
|
|
141
214
|
```bash
|
|
215
|
+
# Masuk ke folder project
|
|
142
216
|
cd my-expo-app
|
|
143
|
-
|
|
217
|
+
|
|
218
|
+
# Jalankan development server
|
|
219
|
+
npm start
|
|
220
|
+
|
|
221
|
+
# Atau langsung ke iOS/Android
|
|
222
|
+
npm run ios
|
|
223
|
+
npm run android
|
|
144
224
|
```
|
|
145
225
|
|
|
146
226
|
---
|
|
147
227
|
|
|
228
|
+
## š” Tips & Best Practices
|
|
148
229
|
|
|
149
|
-
|
|
230
|
+
### Untuk pengguna baru:
|
|
231
|
+
- šÆ Mulai dengan mode interaktif terlebih dahulu: `npx create-ern-boilerplate`
|
|
232
|
+
- š Gunakan template `minimal` untuk belajar struktur dasar
|
|
233
|
+
- š Eksplorasi file yang di-generate untuk memahami setup-nya
|
|
150
234
|
|
|
151
|
-
|
|
235
|
+
### Untuk pengguna berpengalaman:
|
|
236
|
+
- ā” Gunakan alias pendek: `npx ern-boilerplate my-app -y`
|
|
237
|
+
- šØ Kombinasikan dengan opsi custom untuk workflow lebih cepat
|
|
238
|
+
- š§ Template `redux` cocok untuk aplikasi dengan state management kompleks
|
|
152
239
|
|
|
153
|
-
|
|
154
|
-
-
|
|
155
|
-
-
|
|
240
|
+
### Performa:
|
|
241
|
+
- ⨠npx selalu menggunakan versi terbaru dari registry
|
|
242
|
+
- š Gunakan flag `-y` untuk skip semua prompt
|
|
243
|
+
- š¦ Dependencies otomatis terinstall saat menggunakan `-y`
|
|
156
244
|
|
|
157
245
|
---
|
|
158
246
|
|
|
247
|
+
## š¤ Kontribusi
|
|
248
|
+
|
|
249
|
+
Ingin menambahkan template atau fitur baru? Contributions are welcome!
|
|
250
|
+
|
|
251
|
+
1. Fork repository ini
|
|
252
|
+
2. Buat branch baru untuk fitur kamu
|
|
253
|
+
3. Commit perubahan kamu
|
|
254
|
+
4. Push ke branch
|
|
255
|
+
5. Buat Pull Request
|
|
256
|
+
|
|
159
257
|
---
|
|
160
258
|
|
|
161
|
-
##
|
|
259
|
+
## š Lisensi
|
|
162
260
|
|
|
163
261
|
Lisensi: [MIT](./LICENSE)
|
|
164
262
|
|
|
165
263
|
---
|
|
166
264
|
|
|
167
|
-
## š¬
|
|
265
|
+
## š¬ Author
|
|
266
|
+
|
|
267
|
+
Dibuat dengan ā¤ļø oleh **Zedfar**
|
|
268
|
+
|
|
269
|
+
- š§ Email: ulfar.far@gmail.com
|
|
270
|
+
- š GitHub: [@zedfar](https://github.com/zedfar)
|
|
271
|
+
- š¦ NPM: [create-ern-boilerplate](https://www.npmjs.com/package/create-ern-boilerplate)
|
|
272
|
+
|
|
273
|
+
---
|
|
274
|
+
|
|
275
|
+
## š Support
|
|
276
|
+
|
|
277
|
+
Jika tool ini membantu kamu, jangan lupa:
|
|
278
|
+
- ā Star repository ini
|
|
279
|
+
- š Report bugs atau request fitur via [Issues](https://github.com/zedfar/create-ern-boilerplate/issues)
|
|
280
|
+
- š¤ Contribute dengan Pull Request
|
|
281
|
+
|
|
282
|
+
---
|
|
168
283
|
|
|
169
|
-
|
|
170
|
-
š§ Kontak: ulfar.far@gmail.com
|
|
171
|
-
š GitHub: [@zedfar](https://github.com/zedfar)
|
|
284
|
+
**Happy Coding! š**
|
package/create.js
CHANGED
|
@@ -198,29 +198,46 @@ async function main() {
|
|
|
198
198
|
}
|
|
199
199
|
|
|
200
200
|
console.log(`
|
|
201
|
-
${chalk.green("š Selesai!")}
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
? chalk.dim("
|
|
206
|
-
: chalk.
|
|
201
|
+
${chalk.green("š Selesai!")}
|
|
202
|
+
Boilerplate berhasil dibuat untuk project: ${chalk.cyan(projectName)}
|
|
203
|
+
|
|
204
|
+
${autoInstall
|
|
205
|
+
? chalk.dim("š¦ Dependencies sudah terinstall otomatis ā
")
|
|
206
|
+
: chalk.yellow("š¦ Jalankan 'npm install' sebelum mulai coding")
|
|
207
207
|
}
|
|
208
|
-
${chalk.cyan("silahkan mulai code berdasarkan kebutuhan anda")}
|
|
209
208
|
|
|
210
|
-
|
|
209
|
+
${chalk.cyan("Sebelum mulai mengembangkan fitur, sangat disarankan mengikuti urutan bacaan berikut untuk memahami alur project dan AI workflow.")}
|
|
210
|
+
|
|
211
|
+
${chalk.bold("\nš READING ORDER (Urutan Baca yang Direkomendasikan):\n")}
|
|
212
|
+
|
|
213
|
+
1. ā AI_GUIDE.md
|
|
214
|
+
${chalk.dim("# START HERE ā onboarding & cara kerja AI")}
|
|
215
|
+
2. š ai-context.json
|
|
216
|
+
${chalk.dim("# Path mappings & context")}
|
|
217
|
+
3. š GENERATE_RULES.md
|
|
218
|
+
${chalk.dim("# Pola pembuatan kode")}
|
|
219
|
+
4. š CONVENTIONS.md
|
|
220
|
+
${chalk.dim("# Standar coding")}
|
|
221
|
+
5. š” examples/
|
|
222
|
+
${chalk.dim("# Contoh kode siap pakai")}
|
|
223
|
+
6. š README.md
|
|
224
|
+
${chalk.dim("# Gambaran umum project")}
|
|
225
|
+
|
|
226
|
+
${chalk.green("Happy coding! š»")}
|
|
211
227
|
`);
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
228
|
+
|
|
229
|
+
|
|
230
|
+
|
|
231
|
+
// === Helper untuk menampilkan daftar template ===
|
|
232
|
+
async function getTemplateChoices() {
|
|
233
|
+
const templatesDir = path.join(__dirname, "templates");
|
|
234
|
+
const folders = await fs.readdir(templatesDir);
|
|
235
|
+
return folders.filter((f) =>
|
|
236
|
+
fs.statSync(path.join(templatesDir, f)).isDirectory()
|
|
237
|
+
);
|
|
238
|
+
}
|
|
239
|
+
|
|
240
|
+
main().catch((err) => {
|
|
241
|
+
console.error(chalk.red("Terjadi kesalahan:"), err);
|
|
242
|
+
process.exit(1);
|
|
243
|
+
});
|
package/package.json
CHANGED
|
@@ -74,7 +74,8 @@
|
|
|
74
74
|
"react-native-web": "^0.21.0",
|
|
75
75
|
"react-native-webview": "13.15.0",
|
|
76
76
|
"react-native-worklets": "0.5.1",
|
|
77
|
-
"zustand": "^5.0.0"
|
|
77
|
+
"zustand": "^5.0.0",
|
|
78
|
+
"expo-checkbox": "~5.0.7"
|
|
78
79
|
},
|
|
79
80
|
"devDependencies": {
|
|
80
81
|
"@babel/core": "^7.26.0",
|
|
@@ -89,15 +90,5 @@
|
|
|
89
90
|
"tailwindcss": "^3.4.13",
|
|
90
91
|
"typescript": "~5.9.2"
|
|
91
92
|
},
|
|
92
|
-
"private": true
|
|
93
|
-
|
|
94
|
-
"install": {
|
|
95
|
-
"exclude": [
|
|
96
|
-
"react",
|
|
97
|
-
"expo",
|
|
98
|
-
"expo-constants",
|
|
99
|
-
"react-native"
|
|
100
|
-
]
|
|
101
|
-
}
|
|
102
|
-
}
|
|
103
|
-
}
|
|
93
|
+
"private": true
|
|
94
|
+
}
|