@idealyst/cli 1.0.85 → 1.0.86
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/web/vite.config.ts +61 -43
- package/dist/templates/workspace/.devcontainer/Dockerfile +6 -3
- package/dist/templates/workspace/.devcontainer/setup.sh +0 -22
- package/package.json +1 -1
- package/dist/templates/workspace/.devcontainer/README.md +0 -0
- package/dist/templates/workspace/.devcontainer/fix-permissions.sh +0 -0
- package/dist/templates/workspace/.devcontainer/post-create.sh +0 -0
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
4
|
-
import
|
|
1
|
+
import react from "@vitejs/plugin-react";
|
|
2
|
+
import path from "path";
|
|
3
|
+
import { defineConfig } from "vite";
|
|
4
|
+
import babel from "vite-plugin-babel";
|
|
5
5
|
|
|
6
6
|
// https://vitejs.dev/config/
|
|
7
7
|
export default defineConfig({
|
|
@@ -9,23 +9,35 @@ export default defineConfig({
|
|
|
9
9
|
babel({
|
|
10
10
|
filter: (id) =>
|
|
11
11
|
id.includes("node_modules/@idealyst/") ||
|
|
12
|
-
(id.includes("/packages/") &&
|
|
12
|
+
(id.includes("/packages/") &&
|
|
13
|
+
!id.includes("/packages/web/") &&
|
|
14
|
+
/\.(tsx?|jsx?)$/.test(id)),
|
|
13
15
|
babelConfig: {
|
|
14
16
|
presets: [
|
|
15
|
-
[
|
|
16
|
-
[
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
17
|
+
["@babel/preset-react", { runtime: "automatic" }],
|
|
18
|
+
[
|
|
19
|
+
"@babel/preset-typescript",
|
|
20
|
+
{
|
|
21
|
+
isTSX: true,
|
|
22
|
+
allExtensions: true,
|
|
23
|
+
},
|
|
24
|
+
],
|
|
20
25
|
],
|
|
21
26
|
plugins: [
|
|
22
|
-
[
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
27
|
+
[
|
|
28
|
+
"react-native-unistyles/plugin",
|
|
29
|
+
{
|
|
30
|
+
root: "src",
|
|
31
|
+
autoProcessPaths: [
|
|
32
|
+
"@idealyst/components",
|
|
33
|
+
"@idealyst/navigation",
|
|
34
|
+
"@idealyst/theme",
|
|
35
|
+
],
|
|
36
|
+
},
|
|
37
|
+
],
|
|
38
|
+
["@idealyst/components/plugin/web", { root: "src" }],
|
|
39
|
+
],
|
|
40
|
+
},
|
|
29
41
|
}),
|
|
30
42
|
// Then process everything else with React plugin
|
|
31
43
|
react(),
|
|
@@ -33,48 +45,54 @@ export default defineConfig({
|
|
|
33
45
|
resolve: {
|
|
34
46
|
alias: {
|
|
35
47
|
// Use absolute path to resolve react-native-web properly
|
|
36
|
-
|
|
37
|
-
|
|
48
|
+
"react-native": path.resolve(__dirname, "node_modules/react-native-web"),
|
|
49
|
+
"@react-native/normalize-colors": path.resolve(
|
|
50
|
+
__dirname,
|
|
51
|
+
"../../node_modules/@react-native/normalize-colors"
|
|
52
|
+
),
|
|
38
53
|
},
|
|
39
54
|
// Platform-specific file resolution
|
|
40
|
-
extensions: [
|
|
55
|
+
extensions: [".web.tsx", ".web.ts", ".tsx", ".ts", ".js", ".jsx"],
|
|
41
56
|
// Ensure proper resolution of package exports
|
|
42
|
-
conditions: [
|
|
57
|
+
conditions: ["browser", "import", "module", "default"],
|
|
43
58
|
// Ensure workspace dependencies resolve properly
|
|
44
|
-
preserveSymlinks: false
|
|
59
|
+
preserveSymlinks: false,
|
|
45
60
|
},
|
|
46
61
|
define: {
|
|
47
|
-
global:
|
|
62
|
+
global: "globalThis",
|
|
48
63
|
__DEV__: JSON.stringify(true),
|
|
49
64
|
},
|
|
50
65
|
optimizeDeps: {
|
|
51
66
|
include: [
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
'@mdi/js',
|
|
67
|
+
"react-native-web",
|
|
68
|
+
"react-native-unistyles",
|
|
69
|
+
"react-native-unistyles/web",
|
|
70
|
+
"@mdi/react",
|
|
71
|
+
"@mdi/js",
|
|
58
72
|
],
|
|
59
73
|
exclude: [
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
74
|
+
"react-native-edge-to-edge",
|
|
75
|
+
"react-native-nitro-modules",
|
|
76
|
+
"@idealyst/components",
|
|
77
|
+
"@idealyst/navigation",
|
|
78
|
+
"@idealyst/theme",
|
|
79
|
+
"@test/shared",
|
|
66
80
|
],
|
|
67
81
|
esbuildOptions: {
|
|
68
82
|
loader: {
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
}
|
|
74
|
-
|
|
83
|
+
".tsx": "tsx",
|
|
84
|
+
".ts": "ts",
|
|
85
|
+
".jsx": "jsx",
|
|
86
|
+
".js": "jsx", // Important: treat .js files as JSX for React Native compatibility
|
|
87
|
+
},
|
|
88
|
+
alias: {
|
|
89
|
+
"react-native": path.resolve(__dirname, "node_modules/react-native-web"),
|
|
90
|
+
"@react-native/normalize-colors": path.resolve(__dirname, "../../node_modules/@react-native/normalize-colors"),
|
|
91
|
+
},
|
|
92
|
+
},
|
|
75
93
|
},
|
|
76
94
|
server: {
|
|
77
|
-
host:
|
|
95
|
+
host: "0.0.0.0",
|
|
78
96
|
port: 5173,
|
|
79
97
|
},
|
|
80
|
-
})
|
|
98
|
+
});
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
FROM node:20-bullseye
|
|
2
2
|
|
|
3
|
-
# Install additional tools
|
|
3
|
+
# Install additional tools including gosu for proper user switching
|
|
4
4
|
RUN apt-get update && apt-get install -y \
|
|
5
5
|
git \
|
|
6
6
|
postgresql-client \
|
|
@@ -18,6 +18,9 @@ RUN git config --global init.defaultBranch main
|
|
|
18
18
|
# Create workspace directory
|
|
19
19
|
RUN mkdir -p /workspace
|
|
20
20
|
WORKDIR /workspace
|
|
21
|
+
RUN chown -R node:node /workspace
|
|
21
22
|
|
|
22
|
-
#
|
|
23
|
-
|
|
23
|
+
# Note: We don't switch to node user here anymore - entrypoint.sh will do it
|
|
24
|
+
# This allows the entrypoint to fix permissions as root first
|
|
25
|
+
|
|
26
|
+
USER node
|
|
@@ -2,10 +2,6 @@
|
|
|
2
2
|
|
|
3
3
|
echo "🚀 Setting up Idealyst development environment..."
|
|
4
4
|
|
|
5
|
-
# Install dependencies
|
|
6
|
-
echo "📦 Installing dependencies..."
|
|
7
|
-
yarn install
|
|
8
|
-
|
|
9
5
|
# Create environment file if it doesn't exist
|
|
10
6
|
if [ ! -f ".env" ]; then
|
|
11
7
|
echo "📝 Creating .env file..."
|
|
@@ -42,24 +38,6 @@ until pg_isready -h postgres -p 5432 -U postgres; do
|
|
|
42
38
|
sleep 1
|
|
43
39
|
done
|
|
44
40
|
|
|
45
|
-
echo "✅ Database is ready!"
|
|
46
|
-
|
|
47
|
-
# Run database migrations if they exist
|
|
48
|
-
if [ -d "packages" ]; then
|
|
49
|
-
echo "🗄️ Setting up database..."
|
|
50
|
-
|
|
51
|
-
# Check if any package has prisma
|
|
52
|
-
for package_dir in packages/*/; do
|
|
53
|
-
if [ -f "${package_dir}prisma/schema.prisma" ]; then
|
|
54
|
-
echo "Running Prisma setup for $(basename "$package_dir")..."
|
|
55
|
-
cd "$package_dir"
|
|
56
|
-
npx prisma generate
|
|
57
|
-
npx prisma db push
|
|
58
|
-
cd /workspace
|
|
59
|
-
fi
|
|
60
|
-
done
|
|
61
|
-
fi
|
|
62
|
-
|
|
63
41
|
echo "Add Figma MCP to Claude Code"
|
|
64
42
|
claude mcp add -t sse figma-mcp http://figma-mcp:3333/sse
|
|
65
43
|
|
package/package.json
CHANGED
|
File without changes
|
|
File without changes
|
|
File without changes
|