tvi-cli 0.1.4

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 (306) hide show
  1. package/README.md +147 -0
  2. package/dist/index.js +4315 -0
  3. package/package.json +75 -0
  4. package/templates/addons/biome/biome.json.hbs +83 -0
  5. package/templates/addons/husky/.husky/pre-commit +1 -0
  6. package/templates/addons/pwa/apps/web/next/public/favicon/apple-touch-icon.png +0 -0
  7. package/templates/addons/pwa/apps/web/next/public/favicon/favicon-96x96.png +0 -0
  8. package/templates/addons/pwa/apps/web/next/public/favicon/favicon.svg +6 -0
  9. package/templates/addons/pwa/apps/web/next/public/favicon/site.webmanifest.hbs +21 -0
  10. package/templates/addons/pwa/apps/web/next/public/favicon/web-app-manifest-192x192.png +0 -0
  11. package/templates/addons/pwa/apps/web/next/public/favicon/web-app-manifest-512x512.png +0 -0
  12. package/templates/addons/pwa/apps/web/next/src/app/manifest.ts.hbs +26 -0
  13. package/templates/addons/pwa/apps/web/vite/public/logo.png +0 -0
  14. package/templates/addons/pwa/apps/web/vite/pwa-assets.config.ts.hbs +12 -0
  15. package/templates/addons/turborepo/turbo.json.hbs +43 -0
  16. package/templates/api/orpc/native/utils/orpc.ts.hbs +35 -0
  17. package/templates/api/orpc/server/base/src/lib/context.ts.hbs +125 -0
  18. package/templates/api/orpc/server/base/src/lib/orpc.ts.hbs +21 -0
  19. package/templates/api/orpc/server/next/src/app/rpc/[...all]/route.ts.hbs +23 -0
  20. package/templates/api/orpc/web/nuxt/app/plugins/orpc.ts.hbs +35 -0
  21. package/templates/api/orpc/web/react/base/src/utils/orpc.ts.hbs +42 -0
  22. package/templates/api/orpc/web/solid/src/utils/orpc.ts.hbs +30 -0
  23. package/templates/api/orpc/web/svelte/src/lib/orpc.ts.hbs +31 -0
  24. package/templates/api/trpc/native/utils/trpc.ts.hbs +32 -0
  25. package/templates/api/trpc/server/base/src/lib/context.ts.hbs +127 -0
  26. package/templates/api/trpc/server/base/src/lib/trpc.ts.hbs +26 -0
  27. package/templates/api/trpc/server/next/src/app/trpc/[trpc]/route.ts +14 -0
  28. package/templates/api/trpc/web/react/base/src/utils/trpc.ts.hbs +97 -0
  29. package/templates/auth/native/native-base/lib/auth-client.ts.hbs +13 -0
  30. package/templates/auth/native/nativewind/app/(drawer)/index.tsx.hbs +95 -0
  31. package/templates/auth/native/nativewind/components/sign-in.tsx.hbs +93 -0
  32. package/templates/auth/native/nativewind/components/sign-up.tsx.hbs +104 -0
  33. package/templates/auth/native/unistyles/app/(drawer)/index.tsx.hbs +179 -0
  34. package/templates/auth/native/unistyles/components/sign-in.tsx.hbs +134 -0
  35. package/templates/auth/native/unistyles/components/sign-up.tsx.hbs +152 -0
  36. package/templates/auth/server/base/src/lib/auth.ts.hbs +141 -0
  37. package/templates/auth/server/db/drizzle/mysql/src/db/schema/auth.ts +58 -0
  38. package/templates/auth/server/db/drizzle/postgres/src/db/schema/auth.ts +47 -0
  39. package/templates/auth/server/db/drizzle/sqlite/src/db/schema/auth.ts +55 -0
  40. package/templates/auth/server/db/mongoose/mongodb/src/db/models/auth.model.ts +68 -0
  41. package/templates/auth/server/db/prisma/mongodb/prisma/schema/auth.prisma +59 -0
  42. package/templates/auth/server/db/prisma/mysql/prisma/schema/auth.prisma +59 -0
  43. package/templates/auth/server/db/prisma/postgres/prisma/schema/auth.prisma +59 -0
  44. package/templates/auth/server/db/prisma/sqlite/prisma/schema/auth.prisma +59 -0
  45. package/templates/auth/server/next/src/app/api/auth/[...all]/route.ts +4 -0
  46. package/templates/auth/web/nuxt/app/components/SignInForm.vue +77 -0
  47. package/templates/auth/web/nuxt/app/components/SignUpForm.vue +84 -0
  48. package/templates/auth/web/nuxt/app/components/UserMenu.vue +42 -0
  49. package/templates/auth/web/nuxt/app/middleware/auth.ts +12 -0
  50. package/templates/auth/web/nuxt/app/pages/dashboard.vue +27 -0
  51. package/templates/auth/web/nuxt/app/pages/login.vue +24 -0
  52. package/templates/auth/web/nuxt/app/plugins/auth-client.ts +16 -0
  53. package/templates/auth/web/react/base/src/lib/auth-client.ts.hbs +10 -0
  54. package/templates/auth/web/react/next/src/app/dashboard/page.tsx.hbs +47 -0
  55. package/templates/auth/web/react/next/src/app/login/page.tsx +16 -0
  56. package/templates/auth/web/react/next/src/components/sign-in-form.tsx +135 -0
  57. package/templates/auth/web/react/next/src/components/sign-up-form.tsx +160 -0
  58. package/templates/auth/web/react/next/src/components/theme-provider.tsx +11 -0
  59. package/templates/auth/web/react/next/src/components/user-menu.tsx +60 -0
  60. package/templates/auth/web/react/react-router/src/components/sign-in-form.tsx +135 -0
  61. package/templates/auth/web/react/react-router/src/components/sign-up-form.tsx +160 -0
  62. package/templates/auth/web/react/react-router/src/components/user-menu.tsx +60 -0
  63. package/templates/auth/web/react/react-router/src/routes/dashboard.tsx.hbs +40 -0
  64. package/templates/auth/web/react/react-router/src/routes/login.tsx +13 -0
  65. package/templates/auth/web/react/tanstack-router/src/components/sign-in-form.tsx +139 -0
  66. package/templates/auth/web/react/tanstack-router/src/components/sign-up-form.tsx +164 -0
  67. package/templates/auth/web/react/tanstack-router/src/components/user-menu.tsx +62 -0
  68. package/templates/auth/web/react/tanstack-router/src/routes/dashboard.tsx.hbs +47 -0
  69. package/templates/auth/web/react/tanstack-router/src/routes/login.tsx +18 -0
  70. package/templates/auth/web/react/tanstack-start/src/components/sign-in-form.tsx +139 -0
  71. package/templates/auth/web/react/tanstack-start/src/components/sign-up-form.tsx +164 -0
  72. package/templates/auth/web/react/tanstack-start/src/components/user-menu.tsx +62 -0
  73. package/templates/auth/web/react/tanstack-start/src/routes/dashboard.tsx.hbs +51 -0
  74. package/templates/auth/web/react/tanstack-start/src/routes/login.tsx +18 -0
  75. package/templates/auth/web/solid/src/components/sign-in-form.tsx +132 -0
  76. package/templates/auth/web/solid/src/components/sign-up-form.tsx +158 -0
  77. package/templates/auth/web/solid/src/components/user-menu.tsx.hbs +55 -0
  78. package/templates/auth/web/solid/src/lib/auth-client.ts +5 -0
  79. package/templates/auth/web/solid/src/routes/dashboard.tsx +38 -0
  80. package/templates/auth/web/solid/src/routes/login.tsx +23 -0
  81. package/templates/auth/web/svelte/src/components/SignInForm.svelte +108 -0
  82. package/templates/auth/web/svelte/src/components/SignUpForm.svelte +142 -0
  83. package/templates/auth/web/svelte/src/components/UserMenu.svelte +54 -0
  84. package/templates/auth/web/svelte/src/lib/auth-client.ts +6 -0
  85. package/templates/auth/web/svelte/src/routes/dashboard/+page.svelte +31 -0
  86. package/templates/auth/web/svelte/src/routes/login/+page.svelte +12 -0
  87. package/templates/backend/convex/packages/backend/_gitignore +2 -0
  88. package/templates/backend/convex/packages/backend/convex/README.md +90 -0
  89. package/templates/backend/convex/packages/backend/convex/healthCheck.ts +7 -0
  90. package/templates/backend/convex/packages/backend/convex/schema.ts +9 -0
  91. package/templates/backend/convex/packages/backend/convex/todos.ts +42 -0
  92. package/templates/backend/convex/packages/backend/convex/tsconfig.json +25 -0
  93. package/templates/backend/convex/packages/backend/package.json.hbs +17 -0
  94. package/templates/backend/server/elysia/src/index.ts.hbs +72 -0
  95. package/templates/backend/server/express/src/index.ts.hbs +88 -0
  96. package/templates/backend/server/fastify/src/index.ts.hbs +155 -0
  97. package/templates/backend/server/hono/src/index.ts.hbs +133 -0
  98. package/templates/backend/server/next/next-env.d.ts +5 -0
  99. package/templates/backend/server/next/next.config.ts +7 -0
  100. package/templates/backend/server/next/package.json.hbs +24 -0
  101. package/templates/backend/server/next/src/app/route.ts +5 -0
  102. package/templates/backend/server/next/src/middleware.ts +19 -0
  103. package/templates/backend/server/next/tsconfig.json.hbs +33 -0
  104. package/templates/backend/server/server-base/_gitignore +52 -0
  105. package/templates/backend/server/server-base/package.json.hbs +28 -0
  106. package/templates/backend/server/server-base/src/routers/index.ts.hbs +53 -0
  107. package/templates/backend/server/server-base/tsconfig.json.hbs +39 -0
  108. package/templates/base/_gitignore +2 -0
  109. package/templates/base/package.json.hbs +11 -0
  110. package/templates/db/drizzle/mysql/drizzle.config.ts.hbs +10 -0
  111. package/templates/db/drizzle/mysql/src/db/index.ts.hbs +20 -0
  112. package/templates/db/drizzle/postgres/drizzle.config.ts.hbs +10 -0
  113. package/templates/db/drizzle/postgres/src/db/index.ts.hbs +12 -0
  114. package/templates/db/drizzle/sqlite/drizzle.config.ts.hbs +24 -0
  115. package/templates/db/drizzle/sqlite/src/db/index.ts.hbs +35 -0
  116. package/templates/db/mongoose/mongodb/src/db/index.ts.hbs +9 -0
  117. package/templates/db/prisma/mongodb/prisma/index.ts.hbs +5 -0
  118. package/templates/db/prisma/mongodb/prisma/schema/schema.prisma +10 -0
  119. package/templates/db/prisma/mongodb/prisma.config.ts.hbs +8 -0
  120. package/templates/db/prisma/mysql/prisma/index.ts +5 -0
  121. package/templates/db/prisma/mysql/prisma/schema/schema.prisma +10 -0
  122. package/templates/db/prisma/mysql/prisma.config.ts +8 -0
  123. package/templates/db/prisma/postgres/prisma/index.ts +5 -0
  124. package/templates/db/prisma/postgres/prisma/schema/schema.prisma.hbs +13 -0
  125. package/templates/db/prisma/postgres/prisma.config.ts.hbs +12 -0
  126. package/templates/db/prisma/sqlite/prisma/index.ts +5 -0
  127. package/templates/db/prisma/sqlite/prisma/schema/schema.prisma +10 -0
  128. package/templates/db/prisma/sqlite/prisma.config.ts +8 -0
  129. package/templates/examples/ai/native/nativewind/app/(drawer)/ai.tsx.hbs +155 -0
  130. package/templates/examples/ai/native/nativewind/polyfills.js +25 -0
  131. package/templates/examples/ai/native/unistyles/app/(drawer)/ai.tsx.hbs +279 -0
  132. package/templates/examples/ai/native/unistyles/polyfills.js +25 -0
  133. package/templates/examples/ai/server/next/src/app/ai/route.ts +15 -0
  134. package/templates/examples/ai/web/nuxt/app/pages/ai.vue +63 -0
  135. package/templates/examples/ai/web/react/next/src/app/ai/page.tsx +67 -0
  136. package/templates/examples/ai/web/react/react-router/src/routes/ai.tsx +64 -0
  137. package/templates/examples/ai/web/react/tanstack-router/src/routes/ai.tsx +69 -0
  138. package/templates/examples/ai/web/react/tanstack-start/src/routes/ai.tsx +69 -0
  139. package/templates/examples/ai/web/svelte/src/routes/ai/+page.svelte +98 -0
  140. package/templates/examples/todo/native/nativewind/app/(drawer)/todos.tsx.hbs +295 -0
  141. package/templates/examples/todo/native/unistyles/app/(drawer)/todos.tsx.hbs +340 -0
  142. package/templates/examples/todo/server/drizzle/base/src/routers/todo.ts.hbs +79 -0
  143. package/templates/examples/todo/server/drizzle/mysql/src/db/schema/todo.ts +7 -0
  144. package/templates/examples/todo/server/drizzle/postgres/src/db/schema/todo.ts +7 -0
  145. package/templates/examples/todo/server/drizzle/sqlite/src/db/schema/todo.ts +7 -0
  146. package/templates/examples/todo/server/mongoose/base/src/routers/todo.ts.hbs +66 -0
  147. package/templates/examples/todo/server/mongoose/mongodb/src/db/models/todo.model.ts +24 -0
  148. package/templates/examples/todo/server/prisma/base/src/routers/todo.ts.hbs +118 -0
  149. package/templates/examples/todo/server/prisma/mongodb/prisma/schema/todo.prisma +7 -0
  150. package/templates/examples/todo/server/prisma/mysql/prisma/schema/todo.prisma +7 -0
  151. package/templates/examples/todo/server/prisma/postgres/prisma/schema/todo.prisma +7 -0
  152. package/templates/examples/todo/server/prisma/sqlite/prisma/schema/todo.prisma +7 -0
  153. package/templates/examples/todo/web/nuxt/app/pages/todos.vue +108 -0
  154. package/templates/examples/todo/web/react/next/src/app/todos/page.tsx.hbs +245 -0
  155. package/templates/examples/todo/web/react/react-router/src/routes/todos.tsx.hbs +242 -0
  156. package/templates/examples/todo/web/react/tanstack-router/src/routes/todos.tsx.hbs +247 -0
  157. package/templates/examples/todo/web/react/tanstack-start/src/routes/todos.tsx.hbs +268 -0
  158. package/templates/examples/todo/web/solid/src/routes/todos.tsx.hbs +132 -0
  159. package/templates/examples/todo/web/svelte/src/routes/todos/+page.svelte.hbs +317 -0
  160. package/templates/extras/_npmrc.hbs +5 -0
  161. package/templates/extras/pnpm-workspace.yaml +3 -0
  162. package/templates/frontend/native/native-base/assets/adaptive-icon.png +0 -0
  163. package/templates/frontend/native/native-base/assets/favicon.png +0 -0
  164. package/templates/frontend/native/native-base/assets/icon.png +0 -0
  165. package/templates/frontend/native/native-base/assets/splash.png +0 -0
  166. package/templates/frontend/native/nativewind/_gitignore +25 -0
  167. package/templates/frontend/native/nativewind/app/(drawer)/(tabs)/_layout.tsx +46 -0
  168. package/templates/frontend/native/nativewind/app/(drawer)/(tabs)/index.tsx +19 -0
  169. package/templates/frontend/native/nativewind/app/(drawer)/(tabs)/two.tsx +19 -0
  170. package/templates/frontend/native/nativewind/app/(drawer)/_layout.tsx.hbs +67 -0
  171. package/templates/frontend/native/nativewind/app/(drawer)/index.tsx.hbs +95 -0
  172. package/templates/frontend/native/nativewind/app/+html.tsx +47 -0
  173. package/templates/frontend/native/nativewind/app/+not-found.tsx +29 -0
  174. package/templates/frontend/native/nativewind/app/_layout.tsx.hbs +126 -0
  175. package/templates/frontend/native/nativewind/app/modal.tsx +14 -0
  176. package/templates/frontend/native/nativewind/app-env.d.ts +2 -0
  177. package/templates/frontend/native/nativewind/app.json +46 -0
  178. package/templates/frontend/native/nativewind/babel.config.js +11 -0
  179. package/templates/frontend/native/nativewind/components/container.tsx +8 -0
  180. package/templates/frontend/native/nativewind/components/header-button.tsx +26 -0
  181. package/templates/frontend/native/nativewind/components/tabbar-icon.tsx +8 -0
  182. package/templates/frontend/native/nativewind/global.css +50 -0
  183. package/templates/frontend/native/nativewind/lib/android-navigation-bar.tsx +11 -0
  184. package/templates/frontend/native/nativewind/lib/constants.ts +18 -0
  185. package/templates/frontend/native/nativewind/lib/use-color-scheme.ts +12 -0
  186. package/templates/frontend/native/nativewind/metro.config.js +59 -0
  187. package/templates/frontend/native/nativewind/package.json.hbs +49 -0
  188. package/templates/frontend/native/nativewind/tailwind.config.js +59 -0
  189. package/templates/frontend/native/nativewind/tsconfig.json.hbs +23 -0
  190. package/templates/frontend/native/unistyles/_gitignore +24 -0
  191. package/templates/frontend/native/unistyles/app/(drawer)/(tabs)/_layout.tsx +39 -0
  192. package/templates/frontend/native/unistyles/app/(drawer)/(tabs)/index.tsx +37 -0
  193. package/templates/frontend/native/unistyles/app/(drawer)/(tabs)/two.tsx +37 -0
  194. package/templates/frontend/native/unistyles/app/(drawer)/_layout.tsx.hbs +87 -0
  195. package/templates/frontend/native/unistyles/app/(drawer)/index.tsx.hbs +194 -0
  196. package/templates/frontend/native/unistyles/app/+html.tsx +48 -0
  197. package/templates/frontend/native/unistyles/app/+not-found.tsx +65 -0
  198. package/templates/frontend/native/unistyles/app/_layout.tsx.hbs +104 -0
  199. package/templates/frontend/native/unistyles/app/modal.tsx +33 -0
  200. package/templates/frontend/native/unistyles/app.json +44 -0
  201. package/templates/frontend/native/unistyles/babel.config.js +20 -0
  202. package/templates/frontend/native/unistyles/breakpoints.ts +9 -0
  203. package/templates/frontend/native/unistyles/components/container.tsx +15 -0
  204. package/templates/frontend/native/unistyles/components/header-button.tsx +36 -0
  205. package/templates/frontend/native/unistyles/components/tabbar-icon.tsx +8 -0
  206. package/templates/frontend/native/unistyles/expo-env.d.ts +3 -0
  207. package/templates/frontend/native/unistyles/index.js +2 -0
  208. package/templates/frontend/native/unistyles/metro.config.js +20 -0
  209. package/templates/frontend/native/unistyles/package.json.hbs +50 -0
  210. package/templates/frontend/native/unistyles/theme.ts +98 -0
  211. package/templates/frontend/native/unistyles/tsconfig.json.hbs +17 -0
  212. package/templates/frontend/native/unistyles/unistyles.ts +27 -0
  213. package/templates/frontend/nuxt/_gitignore +24 -0
  214. package/templates/frontend/nuxt/app/app.config.ts +15 -0
  215. package/templates/frontend/nuxt/app/app.vue +13 -0
  216. package/templates/frontend/nuxt/app/assets/css/main.css +2 -0
  217. package/templates/frontend/nuxt/app/components/Header.vue.hbs +45 -0
  218. package/templates/frontend/nuxt/app/components/Loader.vue +5 -0
  219. package/templates/frontend/nuxt/app/components/ModeToggle.vue +23 -0
  220. package/templates/frontend/nuxt/app/layouts/default.vue.hbs +11 -0
  221. package/templates/frontend/nuxt/app/pages/index.vue.hbs +57 -0
  222. package/templates/frontend/nuxt/app/plugins/vue-query.ts.hbs +44 -0
  223. package/templates/frontend/nuxt/nuxt.config.ts.hbs +19 -0
  224. package/templates/frontend/nuxt/package.json.hbs +25 -0
  225. package/templates/frontend/nuxt/public/favicon.ico +0 -0
  226. package/templates/frontend/nuxt/public/robots.txt +2 -0
  227. package/templates/frontend/nuxt/server/tsconfig.json +3 -0
  228. package/templates/frontend/nuxt/tsconfig.json.hbs +9 -0
  229. package/templates/frontend/react/next/next-env.d.ts.hbs +5 -0
  230. package/templates/frontend/react/next/next.config.ts.hbs +5 -0
  231. package/templates/frontend/react/next/package.json.hbs +34 -0
  232. package/templates/frontend/react/next/postcss.config.mjs.hbs +5 -0
  233. package/templates/frontend/react/next/src/app/favicon.ico +0 -0
  234. package/templates/frontend/react/next/src/app/layout.tsx.hbs +41 -0
  235. package/templates/frontend/react/next/src/app/page.tsx.hbs +68 -0
  236. package/templates/frontend/react/next/src/components/mode-toggle.tsx.hbs +39 -0
  237. package/templates/frontend/react/next/src/components/providers.tsx.hbs +56 -0
  238. package/templates/frontend/react/next/src/components/theme-provider.tsx.hbs +11 -0
  239. package/templates/frontend/react/next/tsconfig.json.hbs +33 -0
  240. package/templates/frontend/react/react-router/package.json.hbs +42 -0
  241. package/templates/frontend/react/react-router/public/favicon.ico +0 -0
  242. package/templates/frontend/react/react-router/react-router.config.ts +6 -0
  243. package/templates/frontend/react/react-router/src/components/mode-toggle.tsx +37 -0
  244. package/templates/frontend/react/react-router/src/components/theme-provider.tsx +73 -0
  245. package/templates/frontend/react/react-router/src/root.tsx.hbs +152 -0
  246. package/templates/frontend/react/react-router/src/routes/_index.tsx.hbs +74 -0
  247. package/templates/frontend/react/react-router/src/routes.ts +4 -0
  248. package/templates/frontend/react/react-router/tsconfig.json.hbs +32 -0
  249. package/templates/frontend/react/react-router/vite.config.ts.hbs +33 -0
  250. package/templates/frontend/react/tanstack-router/index.html +12 -0
  251. package/templates/frontend/react/tanstack-router/package.json.hbs +41 -0
  252. package/templates/frontend/react/tanstack-router/src/components/mode-toggle.tsx +37 -0
  253. package/templates/frontend/react/tanstack-router/src/components/theme-provider.tsx +73 -0
  254. package/templates/frontend/react/tanstack-router/src/main.tsx.hbs +66 -0
  255. package/templates/frontend/react/tanstack-router/src/routes/__root.tsx.hbs +100 -0
  256. package/templates/frontend/react/tanstack-router/src/routes/index.tsx.hbs +74 -0
  257. package/templates/frontend/react/tanstack-router/tsconfig.json.hbs +23 -0
  258. package/templates/frontend/react/tanstack-router/vite.config.ts.hbs +39 -0
  259. package/templates/frontend/react/tanstack-start/package.json.hbs +44 -0
  260. package/templates/frontend/react/tanstack-start/public/robots.txt +3 -0
  261. package/templates/frontend/react/tanstack-start/src/router.tsx.hbs +144 -0
  262. package/templates/frontend/react/tanstack-start/src/routes/__root.tsx.hbs +97 -0
  263. package/templates/frontend/react/tanstack-start/src/routes/index.tsx.hbs +74 -0
  264. package/templates/frontend/react/tanstack-start/tsconfig.json.hbs +33 -0
  265. package/templates/frontend/react/tanstack-start/vite.config.ts +8 -0
  266. package/templates/frontend/react/web-base/_gitignore +52 -0
  267. package/templates/frontend/react/web-base/components.json +21 -0
  268. package/templates/frontend/react/web-base/src/components/header.tsx.hbs +79 -0
  269. package/templates/frontend/react/web-base/src/components/loader.tsx +9 -0
  270. package/templates/frontend/react/web-base/src/components/ui/button.tsx +59 -0
  271. package/templates/frontend/react/web-base/src/components/ui/card.tsx +92 -0
  272. package/templates/frontend/react/web-base/src/components/ui/checkbox.tsx +30 -0
  273. package/templates/frontend/react/web-base/src/components/ui/dropdown-menu.tsx +257 -0
  274. package/templates/frontend/react/web-base/src/components/ui/input.tsx +21 -0
  275. package/templates/frontend/react/web-base/src/components/ui/label.tsx +22 -0
  276. package/templates/frontend/react/web-base/src/components/ui/skeleton.tsx +13 -0
  277. package/templates/frontend/react/web-base/src/components/ui/sonner.tsx +25 -0
  278. package/templates/frontend/react/web-base/src/index.css +134 -0
  279. package/templates/frontend/react/web-base/src/lib/utils.ts +6 -0
  280. package/templates/frontend/solid/_gitignore +7 -0
  281. package/templates/frontend/solid/index.html +13 -0
  282. package/templates/frontend/solid/package.json.hbs +27 -0
  283. package/templates/frontend/solid/public/robots.txt +3 -0
  284. package/templates/frontend/solid/src/components/header.tsx.hbs +38 -0
  285. package/templates/frontend/solid/src/components/loader.tsx +9 -0
  286. package/templates/frontend/solid/src/main.tsx.hbs +38 -0
  287. package/templates/frontend/solid/src/routes/__root.tsx.hbs +34 -0
  288. package/templates/frontend/solid/src/routes/index.tsx.hbs +61 -0
  289. package/templates/frontend/solid/src/styles.css +5 -0
  290. package/templates/frontend/solid/tsconfig.json.hbs +34 -0
  291. package/templates/frontend/solid/vite.config.js.hbs +39 -0
  292. package/templates/frontend/svelte/_gitignore +23 -0
  293. package/templates/frontend/svelte/_npmrc +1 -0
  294. package/templates/frontend/svelte/package.json.hbs +31 -0
  295. package/templates/frontend/svelte/src/app.css +5 -0
  296. package/templates/frontend/svelte/src/app.d.ts +13 -0
  297. package/templates/frontend/svelte/src/app.html +12 -0
  298. package/templates/frontend/svelte/src/components/Header.svelte.hbs +40 -0
  299. package/templates/frontend/svelte/src/lib/index.ts +1 -0
  300. package/templates/frontend/svelte/src/routes/+layout.svelte.hbs +54 -0
  301. package/templates/frontend/svelte/src/routes/+page.svelte.hbs +72 -0
  302. package/templates/frontend/svelte/static/favicon.png +0 -0
  303. package/templates/frontend/svelte/svelte.config.js +18 -0
  304. package/templates/frontend/svelte/tsconfig.json.hbs +24 -0
  305. package/templates/frontend/svelte/vite.config.ts +7 -0
  306. package/templates/runtime/workers/apps/server/wrangler.jsonc.hbs +34 -0
@@ -0,0 +1,126 @@
1
+ {{#if (includes examples "ai")}}
2
+ import "@/polyfills";
3
+ {{/if}}
4
+ {{#if (eq backend "convex")}}
5
+ import { ConvexProvider, ConvexReactClient } from "convex/react";
6
+ {{else}}
7
+ {{#unless (eq api "none")}}
8
+ import { QueryClientProvider } from "@tanstack/react-query";
9
+ {{/unless}}
10
+ {{/if}}
11
+ import { Stack } from "expo-router";
12
+ import {
13
+ DarkTheme,
14
+ DefaultTheme,
15
+ type Theme,
16
+ ThemeProvider,
17
+ } from "@react-navigation/native";
18
+ import { StatusBar } from "expo-status-bar";
19
+ import { GestureHandlerRootView } from "react-native-gesture-handler";
20
+ import "../global.css";
21
+ {{#if (eq api "trpc")}}
22
+ import { queryClient } from "@/utils/trpc";
23
+ {{/if}}
24
+ {{#if (eq api "orpc")}}
25
+ import { queryClient } from "@/utils/orpc";
26
+ {{/if}}
27
+ import { NAV_THEME } from "@/lib/constants";
28
+ import React, { useRef } from "react";
29
+ import { useColorScheme } from "@/lib/use-color-scheme";
30
+ import { Platform } from "react-native";
31
+ import { setAndroidNavigationBar } from "@/lib/android-navigation-bar";
32
+
33
+ const LIGHT_THEME: Theme = {
34
+ ...DefaultTheme,
35
+ colors: NAV_THEME.light,
36
+ };
37
+ const DARK_THEME: Theme = {
38
+ ...DarkTheme,
39
+ colors: NAV_THEME.dark,
40
+ };
41
+
42
+ export const unstable_settings = {
43
+ initialRouteName: "(drawer)",
44
+ };
45
+
46
+ {{#if (eq backend "convex")}}
47
+ const convex = new ConvexReactClient(process.env.EXPO_PUBLIC_CONVEX_URL!, {
48
+ unsavedChangesWarning: false,
49
+ });
50
+ {{/if}}
51
+
52
+ export default function RootLayout() {
53
+ const hasMounted = useRef(false);
54
+ const { colorScheme, isDarkColorScheme } = useColorScheme();
55
+ const [isColorSchemeLoaded, setIsColorSchemeLoaded] = React.useState(false);
56
+
57
+ useIsomorphicLayoutEffect(() => {
58
+ if (hasMounted.current) {
59
+ return;
60
+ }
61
+
62
+ if (Platform.OS === "web") {
63
+ document.documentElement.classList.add("bg-background");
64
+ }
65
+ setAndroidNavigationBar(colorScheme);
66
+ setIsColorSchemeLoaded(true);
67
+ hasMounted.current = true;
68
+ }, []);
69
+
70
+ if (!isColorSchemeLoaded) {
71
+ return null;
72
+ }
73
+ return (
74
+ {{#if (eq backend "convex")}}
75
+ <ConvexProvider client={convex}>
76
+ <ThemeProvider value={isDarkColorScheme ? DARK_THEME : LIGHT_THEME}>
77
+ <StatusBar style={isDarkColorScheme ? "light" : "dark"} />
78
+ <GestureHandlerRootView style=\{{ flex: 1 }}>
79
+ <Stack>
80
+ <Stack.Screen name="(drawer)" options=\{{ headerShown: false }} />
81
+ <Stack.Screen
82
+ name="modal"
83
+ options=\{{ title: "Modal", presentation: "modal" }}
84
+ />
85
+ </Stack>
86
+ </GestureHandlerRootView>
87
+ </ThemeProvider>
88
+ </ConvexProvider>
89
+ {{else}}
90
+ {{#unless (eq api "none")}}
91
+ <QueryClientProvider client={queryClient}>
92
+ <ThemeProvider value={isDarkColorScheme ? DARK_THEME : LIGHT_THEME}>
93
+ <StatusBar style={isDarkColorScheme ? "light" : "dark"} />
94
+ <GestureHandlerRootView style=\{{ flex: 1 }}>
95
+ <Stack>
96
+ <Stack.Screen name="(drawer)" options=\{{ headerShown: false }} />
97
+ <Stack.Screen
98
+ name="modal"
99
+ options=\{{ title: "Modal", presentation: "modal" }}
100
+ />
101
+ </Stack>
102
+ </GestureHandlerRootView>
103
+ </ThemeProvider>
104
+ </QueryClientProvider>
105
+ {{else}}
106
+ <ThemeProvider value={isDarkColorScheme ? DARK_THEME : LIGHT_THEME}>
107
+ <StatusBar style={isDarkColorScheme ? "light" : "dark"} />
108
+ <GestureHandlerRootView style=\{{ flex: 1 }}>
109
+ <Stack>
110
+ <Stack.Screen name="(drawer)" options=\{{ headerShown: false }} />
111
+ <Stack.Screen
112
+ name="modal"
113
+ options=\{{ title: "Modal", presentation: "modal" }}
114
+ />
115
+ </Stack>
116
+ </GestureHandlerRootView>
117
+ </ThemeProvider>
118
+ {{/unless}}
119
+ {{/if}}
120
+ );
121
+ }
122
+
123
+ const useIsomorphicLayoutEffect =
124
+ Platform.OS === "web" && typeof window === "undefined"
125
+ ? React.useEffect
126
+ : React.useLayoutEffect;
@@ -0,0 +1,14 @@
1
+ import { Container } from "@/components/container";
2
+ import { Text, View } from "react-native";
3
+
4
+ export default function Modal() {
5
+ return (
6
+ <Container>
7
+ <View className="flex-1 p-6">
8
+ <View className="flex-row items-center justify-between mb-8">
9
+ <Text className="text-2xl font-bold text-foreground">Modal</Text>
10
+ </View>
11
+ </View>
12
+ </Container>
13
+ );
14
+ }
@@ -0,0 +1,2 @@
1
+ // @ts-ignore
2
+ /// <reference types="nativewind/types" />
@@ -0,0 +1,46 @@
1
+ {
2
+ "expo": {
3
+ "name": "my-tvi-app",
4
+ "slug": "my-tvi-app",
5
+ "version": "1.0.0",
6
+ "scheme": "my-tvi-app",
7
+ "web": {
8
+ "bundler": "metro",
9
+ "output": "static",
10
+ "favicon": "./assets/favicon.png"
11
+ },
12
+ "plugins": [
13
+ "expo-router",
14
+ "expo-secure-store",
15
+ "expo-web-browser"
16
+ ],
17
+ "experiments": {
18
+ "typedRoutes": true,
19
+ "tsconfigPaths": true
20
+ },
21
+ "newArchEnabled": true,
22
+ "orientation": "portrait",
23
+ "icon": "./assets/icon.png",
24
+ "userInterfaceStyle": "light",
25
+ "splash": {
26
+ "image": "./assets/splash.png",
27
+ "resizeMode": "contain",
28
+ "backgroundColor": "#ffffff"
29
+ },
30
+ "assetBundlePatterns": [
31
+ "**/*"
32
+ ],
33
+ "ios": {
34
+ "supportsTablet": true,
35
+ "bundleIdentifier": "com.shaneholloman.tvi"
36
+ },
37
+ "android": {
38
+ "adaptiveIcon": {
39
+ "foregroundImage": "./assets/adaptive-icon.png",
40
+ "backgroundColor": "#ffffff"
41
+ },
42
+ "package": "com.shaneholloman.tvi",
43
+ "edgeToEdgeEnabled": true
44
+ }
45
+ }
46
+ }
@@ -0,0 +1,11 @@
1
+ module.exports = function (api) {
2
+ api.cache(true);
3
+ const plugins = [];
4
+
5
+ plugins.push('react-native-reanimated/plugin');
6
+
7
+ return {
8
+ presets: [['babel-preset-expo', { jsxImportSource: 'nativewind' }], 'nativewind/babel'],
9
+ plugins,
10
+ };
11
+ };
@@ -0,0 +1,8 @@
1
+ import React from "react";
2
+ import { SafeAreaView } from "react-native";
3
+
4
+ export const Container = ({ children }: { children: React.ReactNode }) => {
5
+ return (
6
+ <SafeAreaView className="flex-1 bg-background">{children}</SafeAreaView>
7
+ );
8
+ };
@@ -0,0 +1,26 @@
1
+ import FontAwesome from "@expo/vector-icons/FontAwesome";
2
+ import { forwardRef } from "react";
3
+ import { Pressable } from "react-native";
4
+
5
+ export const HeaderButton = forwardRef<
6
+ typeof Pressable,
7
+ { onPress?: () => void }
8
+ >(({ onPress }, ref) => {
9
+ return (
10
+ <Pressable
11
+ onPress={onPress}
12
+ className="p-2 mr-2 rounded-lg bg-secondary/50 active:bg-secondary"
13
+ >
14
+ {({ pressed }) => (
15
+ <FontAwesome
16
+ name="info-circle"
17
+ size={20}
18
+ className="text-secondary-foreground"
19
+ style={{
20
+ opacity: pressed ? 0.7 : 1,
21
+ }}
22
+ />
23
+ )}
24
+ </Pressable>
25
+ );
26
+ });
@@ -0,0 +1,8 @@
1
+ import FontAwesome from "@expo/vector-icons/FontAwesome";
2
+
3
+ export const TabBarIcon = (props: {
4
+ name: React.ComponentProps<typeof FontAwesome>["name"];
5
+ color: string;
6
+ }) => {
7
+ return <FontAwesome size={24} style={{ marginBottom: -3 }} {...props} />;
8
+ };
@@ -0,0 +1,50 @@
1
+ @tailwind base;
2
+ @tailwind components;
3
+ @tailwind utilities;
4
+
5
+ @layer base {
6
+ :root {
7
+ --background: 0 0% 100%;
8
+ --foreground: 222.2 84% 4.9%;
9
+ --card: 0 0% 100%;
10
+ --card-foreground: 222.2 84% 4.9%;
11
+ --popover: 0 0% 100%;
12
+ --popover-foreground: 222.2 84% 4.9%;
13
+ --primary: 221.2 83.2% 53.3%;
14
+ --primary-foreground: 210 40% 98%;
15
+ --secondary: 210 40% 96%;
16
+ --secondary-foreground: 222.2 84% 4.9%;
17
+ --muted: 210 40% 96%;
18
+ --muted-foreground: 215.4 16.3% 40%;
19
+ --accent: 210 40% 96%;
20
+ --accent-foreground: 222.2 84% 4.9%;
21
+ --destructive: 0 84.2% 60.2%;
22
+ --destructive-foreground: 210 40% 98%;
23
+ --border: 214.3 31.8% 91.4%;
24
+ --input: 214.3 31.8% 91.4%;
25
+ --ring: 221.2 83.2% 53.3%;
26
+ --radius: 8px;
27
+ }
28
+
29
+ .dark:root {
30
+ --background: 222.2 84% 4.9%;
31
+ --foreground: 210 40% 98%;
32
+ --card: 222.2 84% 4.9%;
33
+ --card-foreground: 210 40% 98%;
34
+ --popover: 222.2 84% 4.9%;
35
+ --popover-foreground: 210 40% 98%;
36
+ --primary: 217.2 91.2% 59.8%;
37
+ --primary-foreground: 222.2 84% 4.9%;
38
+ --secondary: 217.2 32.6% 17.5%;
39
+ --secondary-foreground: 210 40% 98%;
40
+ --muted: 217.2 32.6% 17.5%;
41
+ --muted-foreground: 215 20.2% 70%;
42
+ --accent: 217.2 32.6% 17.5%;
43
+ --accent-foreground: 210 40% 98%;
44
+ --destructive: 0 72% 51%;
45
+ --destructive-foreground: 210 40% 98%;
46
+ --border: 217.2 32.6% 17.5%;
47
+ --input: 217.2 32.6% 17.5%;
48
+ --ring: 224.3 76.3% 94.1%;
49
+ }
50
+ }
@@ -0,0 +1,11 @@
1
+ import * as NavigationBar from "expo-navigation-bar";
2
+ import { Platform } from "react-native";
3
+ import { NAV_THEME } from "@/lib/constants";
4
+
5
+ export async function setAndroidNavigationBar(theme: "light" | "dark") {
6
+ if (Platform.OS !== "android") return;
7
+ await NavigationBar.setButtonStyleAsync(theme === "dark" ? "light" : "dark");
8
+ await NavigationBar.setBackgroundColorAsync(
9
+ theme === "dark" ? NAV_THEME.dark.background : NAV_THEME.light.background,
10
+ );
11
+ }
@@ -0,0 +1,18 @@
1
+ export const NAV_THEME = {
2
+ light: {
3
+ background: "hsl(0 0% 100%)",
4
+ border: "hsl(220 13% 91%)",
5
+ card: "hsl(0 0% 100%)",
6
+ notification: "hsl(0 84.2% 60.2%)",
7
+ primary: "hsl(221.2 83.2% 53.3%)",
8
+ text: "hsl(222.2 84% 4.9%)",
9
+ },
10
+ dark: {
11
+ background: "hsl(222.2 84% 4.9%)",
12
+ border: "hsl(217.2 32.6% 17.5%)",
13
+ card: "hsl(222.2 84% 4.9%)",
14
+ notification: "hsl(0 72% 51%)",
15
+ primary: "hsl(217.2 91.2% 59.8%)",
16
+ text: "hsl(210 40% 98%)",
17
+ },
18
+ };
@@ -0,0 +1,12 @@
1
+ import { useColorScheme as useNativewindColorScheme } from "nativewind";
2
+
3
+ export function useColorScheme() {
4
+ const { colorScheme, setColorScheme, toggleColorScheme } =
5
+ useNativewindColorScheme();
6
+ return {
7
+ colorScheme: colorScheme ?? "dark",
8
+ isDarkColorScheme: colorScheme === "dark",
9
+ setColorScheme,
10
+ toggleColorScheme,
11
+ };
12
+ }
@@ -0,0 +1,59 @@
1
+ // Learn more https://docs.expo.io/guides/customizing-metro
2
+ const { getDefaultConfig } = require("expo/metro-config");
3
+ const { FileStore } = require("metro-cache");
4
+ const { withNativeWind } = require("nativewind/metro");
5
+ const path = require("node:path");
6
+
7
+ const config = withTurborepoManagedCache(
8
+ withMonorepoPaths(
9
+ withNativeWind(getDefaultConfig(__dirname), {
10
+ input: "./global.css",
11
+ configPath: "./tailwind.config.js",
12
+ }),
13
+ ),
14
+ );
15
+
16
+ config.resolver.unstable_enablePackageExports = true;
17
+
18
+ config.resolver.disableHierarchicalLookup = true;
19
+
20
+ module.exports = config;
21
+
22
+ /**
23
+ * Add the monorepo paths to the Metro config.
24
+ * This allows Metro to resolve modules from the monorepo.
25
+ *
26
+ * @see https://docs.expo.dev/guides/monorepos/#modify-the-metro-config
27
+ * @param {import('expo/metro-config').MetroConfig} config
28
+ * @returns {import('expo/metro-config').MetroConfig}
29
+ */
30
+ function withMonorepoPaths(config) {
31
+ const projectRoot = __dirname;
32
+ const workspaceRoot = path.resolve(projectRoot, "../..");
33
+
34
+ // #1 - Watch all files in the monorepo
35
+ config.watchFolders = [workspaceRoot];
36
+
37
+ // #2 - Resolve modules within the project's `node_modules` first, then all monorepo modules
38
+ config.resolver.nodeModulesPaths = [
39
+ path.resolve(projectRoot, "node_modules"),
40
+ path.resolve(workspaceRoot, "node_modules"),
41
+ ];
42
+
43
+ return config;
44
+ }
45
+
46
+ /**
47
+ * Move the Metro cache to the `.cache/metro` folder.
48
+ * If you have any environment variables, you can configure Turborepo to invalidate it when needed.
49
+ *
50
+ * @see https://turbo.build/repo/docs/reference/configuration#env
51
+ * @param {import('expo/metro-config').MetroConfig} config
52
+ * @returns {import('expo/metro-config').MetroConfig}
53
+ */
54
+ function withTurborepoManagedCache(config) {
55
+ config.cacheStores = [
56
+ new FileStore({ root: path.join(__dirname, ".cache/metro") }),
57
+ ];
58
+ return config;
59
+ }
@@ -0,0 +1,49 @@
1
+ {
2
+ "name": "native",
3
+ "version": "1.0.0",
4
+ "main": "expo-router/entry",
5
+ "scripts": {
6
+ "dev": "expo start --clear",
7
+ "android": "expo run:android",
8
+ "ios": "expo run:ios",
9
+ "prebuild": "expo prebuild",
10
+ "web": "expo start --web"
11
+ },
12
+ "dependencies": {
13
+ "@expo/vector-icons": "^14.0.4",
14
+ "@react-navigation/bottom-tabs": "^7.2.0",
15
+ "@react-navigation/drawer": "^7.1.1",
16
+ "@react-navigation/native": "^7.0.14",
17
+ "@tanstack/react-form": "^1.0.5",
18
+ "@tanstack/react-query": "^5.69.2",
19
+ {{#if (includes examples "ai")}}
20
+ "@stardazed/streams-text-encoding": "^1.0.2",
21
+ "@ungap/structured-clone": "^1.3.0",
22
+ {{/if}}
23
+ "expo": "^53.0.4",
24
+ "expo-constants": "~17.1.4",
25
+ "expo-linking": "~7.1.4",
26
+ "expo-navigation-bar": "~4.2.3",
27
+ "expo-router": "~5.0.3",
28
+ "expo-secure-store": "~14.2.3",
29
+ "expo-status-bar": "~2.2.3",
30
+ "expo-system-ui": "~5.0.6",
31
+ "expo-web-browser": "~14.1.6",
32
+ "nativewind": "^4.1.23",
33
+ "react": "19.0.0",
34
+ "react-dom": "19.0.0",
35
+ "react-native": "0.79.1",
36
+ "react-native-gesture-handler": "~2.24.0",
37
+ "react-native-reanimated": "~3.17.4",
38
+ "react-native-safe-area-context": "5.3.0",
39
+ "react-native-screens": "~4.10.0",
40
+ "react-native-web": "^0.20.0"
41
+ },
42
+ "devDependencies": {
43
+ "@babel/core": "^7.26.10",
44
+ "@types/react": "~19.0.10",
45
+ "tailwindcss": "^3.4.17",
46
+ "typescript": "~5.8.2"
47
+ },
48
+ "private": true
49
+ }
@@ -0,0 +1,59 @@
1
+ const { hairlineWidth } = require("nativewind/theme");
2
+
3
+ /** @type {import('tailwindcss').Config} */
4
+ module.exports = {
5
+ darkMode: "class",
6
+ content: ["./app/**/*.{js,ts,tsx}", "./components/**/*.{js,ts,tsx}"],
7
+
8
+ presets: [require("nativewind/preset")],
9
+ theme: {
10
+ extend: {
11
+ colors: {
12
+ background: "hsl(var(--background))",
13
+ foreground: "hsl(var(--foreground))",
14
+ card: {
15
+ DEFAULT: "hsl(var(--card))",
16
+ foreground: "hsl(var(--card-foreground))",
17
+ },
18
+ popover: {
19
+ DEFAULT: "hsl(var(--popover))",
20
+ foreground: "hsl(var(--popover-foreground))",
21
+ },
22
+ primary: {
23
+ DEFAULT: "hsl(var(--primary))",
24
+ foreground: "hsl(var(--primary-foreground))",
25
+ },
26
+ secondary: {
27
+ DEFAULT: "hsl(var(--secondary))",
28
+ foreground: "hsl(var(--secondary-foreground))",
29
+ },
30
+ muted: {
31
+ DEFAULT: "hsl(var(--muted))",
32
+ foreground: "hsl(var(--muted-foreground))",
33
+ },
34
+ accent: {
35
+ DEFAULT: "hsl(var(--accent))",
36
+ foreground: "hsl(var(--accent-foreground))",
37
+ },
38
+ destructive: {
39
+ DEFAULT: "hsl(var(--destructive))",
40
+ foreground: "hsl(var(--destructive-foreground))",
41
+ },
42
+ border: "hsl(var(--border))",
43
+ input: "hsl(var(--input))",
44
+ ring: "hsl(var(--ring))",
45
+ radius: "var(--radius)",
46
+ },
47
+ borderRadius: {
48
+ xl: "calc(var(--radius) + 4px)",
49
+ lg: "var(--radius)",
50
+ md: "calc(var(--radius) - 2px)",
51
+ sm: "calc(var(--radius) - 4px)",
52
+ },
53
+ borderWidth: {
54
+ hairline: hairlineWidth(),
55
+ },
56
+ },
57
+ },
58
+ plugins: [],
59
+ };
@@ -0,0 +1,23 @@
1
+ {
2
+ "extends": "expo/tsconfig.base",
3
+ "compilerOptions": {
4
+ "strict": true,
5
+ "paths": {
6
+ "@/*": [
7
+ "./*"
8
+ ]
9
+ }
10
+ },
11
+ "include": [
12
+ "**/*.ts",
13
+ "**/*.tsx",
14
+ ".expo/types/**/*.ts",
15
+ "expo-env.d.ts",
16
+ "nativewind-env.d.ts"
17
+ ],
18
+ {{#unless (or (eq backend "convex") (eq backend "none"))}}
19
+ "references": [{
20
+ "path": "../server"
21
+ }]
22
+ {{/unless}}
23
+ }
@@ -0,0 +1,24 @@
1
+ node_modules/
2
+ .expo/
3
+ dist/
4
+ npm-debug.*
5
+ *.jks
6
+ *.p8
7
+ *.p12
8
+ *.key
9
+ *.mobileprovision
10
+ *.orig.*
11
+ web-build/
12
+ # expo router
13
+ expo-env.d.ts
14
+
15
+
16
+
17
+ ios
18
+ android
19
+
20
+ # macOS
21
+ .DS_Store
22
+
23
+ # Temporary files created by Metro to check the health of the file watcher
24
+ .metro-health-check*
@@ -0,0 +1,39 @@
1
+ import { Tabs } from "expo-router";
2
+ import { useUnistyles } from "react-native-unistyles";
3
+
4
+ import { TabBarIcon } from "@/components/tabbar-icon";
5
+
6
+ export default function TabLayout() {
7
+ const { theme } = useUnistyles();
8
+
9
+ return (
10
+ <Tabs
11
+ screenOptions={{
12
+ headerShown: false,
13
+ tabBarActiveTintColor: theme.colors.primary,
14
+ tabBarInactiveTintColor: theme.colors.mutedForeground,
15
+ tabBarStyle: {
16
+ backgroundColor: theme.colors.background,
17
+ borderTopColor: theme.colors.border,
18
+ },
19
+ }}
20
+ >
21
+ <Tabs.Screen
22
+ name="index"
23
+ options={{
24
+ title: "Home",
25
+ tabBarIcon: ({ color }) => <TabBarIcon name="home" color={color} />,
26
+ }}
27
+ />
28
+ <Tabs.Screen
29
+ name="two"
30
+ options={{
31
+ title: "Explore",
32
+ tabBarIcon: ({ color }) => (
33
+ <TabBarIcon name="compass" color={color} />
34
+ ),
35
+ }}
36
+ />
37
+ </Tabs>
38
+ );
39
+ }
@@ -0,0 +1,37 @@
1
+ import { Container } from "@/components/container";
2
+ import { ScrollView, Text, View } from "react-native";
3
+ import { StyleSheet } from "react-native-unistyles";
4
+
5
+ export default function Home() {
6
+ return (
7
+ <Container>
8
+ <ScrollView contentContainerStyle={styles.container}>
9
+ <View style={styles.headerSection}>
10
+ <Text style={styles.title}>Tab One</Text>
11
+ <Text style={styles.subtitle}>
12
+ Explore the first section of your app
13
+ </Text>
14
+ </View>
15
+ </ScrollView>
16
+ </Container>
17
+ );
18
+ }
19
+
20
+ const styles = StyleSheet.create((theme) => ({
21
+ container: {
22
+ padding: theme.spacing.lg,
23
+ },
24
+ headerSection: {
25
+ paddingVertical: theme.spacing.xl,
26
+ },
27
+ title: {
28
+ fontSize: theme.fontSize["3xl"],
29
+ fontWeight: "bold",
30
+ color: theme.colors.foreground,
31
+ marginBottom: theme.spacing.sm,
32
+ },
33
+ subtitle: {
34
+ fontSize: theme.fontSize.lg,
35
+ color: theme.colors.mutedForeground,
36
+ },
37
+ }));
@@ -0,0 +1,37 @@
1
+ import { Container } from "@/components/container";
2
+ import { ScrollView, Text, View } from "react-native";
3
+ import { StyleSheet } from "react-native-unistyles";
4
+
5
+ export default function TabTwo() {
6
+ return (
7
+ <Container>
8
+ <ScrollView contentContainerStyle={styles.container}>
9
+ <View style={styles.headerSection}>
10
+ <Text style={styles.title}>Tab Two</Text>
11
+ <Text style={styles.subtitle}>
12
+ Discover more features and content
13
+ </Text>
14
+ </View>
15
+ </ScrollView>
16
+ </Container>
17
+ );
18
+ }
19
+
20
+ const styles = StyleSheet.create((theme) => ({
21
+ container: {
22
+ padding: theme.spacing.lg,
23
+ },
24
+ headerSection: {
25
+ paddingVertical: theme.spacing.xl,
26
+ },
27
+ title: {
28
+ fontSize: theme.fontSize["3xl"],
29
+ fontWeight: "bold",
30
+ color: theme.colors.foreground,
31
+ marginBottom: theme.spacing.sm,
32
+ },
33
+ subtitle: {
34
+ fontSize: theme.fontSize.lg,
35
+ color: theme.colors.mutedForeground,
36
+ },
37
+ }));