nexforge-cli 1.0.10 → 1.1.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.
- package/README.md +19 -9
- package/index.js +23 -12
- package/package.json +4 -2
- package/src/commands/create.js +197 -293
- package/src/commands/deploy.js +10 -10
- package/src/commands/domains.js +7 -7
- package/src/commands/env.js +7 -7
- package/src/commands/info.js +7 -7
- package/src/commands/init.js +7 -6
- package/src/commands/login.js +6 -5
- package/src/commands/logs.js +5 -5
- package/src/commands/open.js +8 -8
- package/src/commands/rename.js +7 -6
- package/src/commands/rollback.js +7 -6
- package/src/config.js +14 -12
- package/src/templates/backend/express-mongodb/package.json +39 -0
- package/src/templates/backend/express-mongodb/src/config/.gitkeep +0 -0
- package/src/templates/backend/express-mongodb/src/controllers/.gitkeep +0 -0
- package/src/templates/backend/express-mongodb/src/middlewares/.gitkeep +0 -0
- package/src/templates/backend/express-mongodb/src/models/.gitkeep +0 -0
- package/src/templates/backend/express-mongodb/src/routes/.gitkeep +0 -0
- package/src/templates/backend/express-mongodb/src/server.js +12 -0
- package/src/templates/backend/express-mongodb/src/services/.gitkeep +0 -0
- package/src/templates/backend/express-mongodb/src/utils/.gitkeep +0 -0
- package/src/templates/backend/express-postgres/package.json +39 -0
- package/src/templates/backend/express-postgres/src/config/.gitkeep +0 -0
- package/src/templates/backend/express-postgres/src/controllers/.gitkeep +0 -0
- package/src/templates/backend/express-postgres/src/middlewares/.gitkeep +0 -0
- package/src/templates/backend/express-postgres/src/models/.gitkeep +0 -0
- package/src/templates/backend/express-postgres/src/routes/.gitkeep +0 -0
- package/src/templates/backend/express-postgres/src/server.js +16 -0
- package/src/templates/backend/express-postgres/src/services/.gitkeep +0 -0
- package/src/templates/backend/express-postgres/src/utils/.gitkeep +0 -0
- package/src/templates/backend/express-sql/package.json +39 -0
- package/src/templates/backend/express-sql/src/config/.gitkeep +0 -0
- package/src/templates/backend/express-sql/src/controllers/.gitkeep +0 -0
- package/src/templates/backend/express-sql/src/middlewares/.gitkeep +0 -0
- package/src/templates/backend/express-sql/src/models/.gitkeep +0 -0
- package/src/templates/backend/express-sql/src/routes/.gitkeep +0 -0
- package/src/templates/backend/express-sql/src/server.js +15 -0
- package/src/templates/backend/express-sql/src/services/.gitkeep +0 -0
- package/src/templates/backend/express-sql/src/utils/.gitkeep +0 -0
- package/src/templates/frontend/react/index.html +12 -0
- package/src/templates/frontend/react/package.json +37 -0
- package/src/templates/frontend/react/postcss.config.js +1 -0
- package/src/templates/frontend/react/src/App.jsx +11 -0
- package/src/templates/frontend/react/src/assets/.gitkeep +0 -0
- package/src/templates/frontend/react/src/components/.gitkeep +0 -0
- package/src/templates/frontend/react/src/hooks/.gitkeep +0 -0
- package/src/templates/frontend/react/src/index.css +3 -0
- package/src/templates/frontend/react/src/lib/utils.js +6 -0
- package/src/templates/frontend/react/src/main.jsx +10 -0
- package/src/templates/frontend/react/src/pages/.gitkeep +0 -0
- package/src/templates/frontend/react/src/redux/.gitkeep +0 -0
- package/src/templates/frontend/react/src/services/.gitkeep +0 -0
- package/src/templates/frontend/react/src/utils/.gitkeep +0 -0
- package/src/templates/frontend/react/tailwind.config.js +6 -0
- package/src/templates/frontend/react/vite.config.js +6 -0
- package/src/templates/frontend/vue/index.html +13 -0
- package/src/templates/frontend/vue/package.json +18 -0
- package/src/templates/frontend/vue/src/App.vue +11 -0
- package/src/templates/frontend/vue/src/main.js +5 -0
- package/src/templates/frontend/vue/src/style.css +1 -0
- package/src/templates/frontend/vue/vite.config.js +6 -0
package/src/commands/deploy.js
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
1
|
+
import fs from 'fs'
|
|
2
|
+
import path from 'path'
|
|
3
|
+
import chalk from 'chalk'
|
|
4
|
+
import ora from 'ora'
|
|
5
|
+
import archiver from 'archiver'
|
|
6
|
+
import FormData from 'form-data'
|
|
7
|
+
import { axios, API_BASE_URL, CONFIG_FILE } from '../config.js'
|
|
8
|
+
|
|
9
|
+
export default (program) => {
|
|
10
10
|
program
|
|
11
11
|
.command("deploy")
|
|
12
12
|
.description("Deploy the current directory to NexForge")
|
|
@@ -71,7 +71,7 @@ module.exports = (program) => {
|
|
|
71
71
|
console.log(chalk.gray(`Streaming live build logs...\n`))
|
|
72
72
|
|
|
73
73
|
// Automatically stream logs after deployment
|
|
74
|
-
const io =
|
|
74
|
+
const { default: io } = await import('socket.io-client')
|
|
75
75
|
const socket = io(API_BASE_URL.replace("/api", ""), {
|
|
76
76
|
transports: ["websocket", "polling"],
|
|
77
77
|
})
|
package/src/commands/domains.js
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
1
|
+
import fs from 'fs'
|
|
2
|
+
import path from 'path'
|
|
3
|
+
import axios from 'axios'
|
|
4
|
+
import chalk from 'chalk'
|
|
5
|
+
import ora from 'ora'
|
|
6
|
+
import { getNexforgeConfig } from '../config.js'
|
|
7
7
|
|
|
8
|
-
|
|
8
|
+
export default (program) => {
|
|
9
9
|
program
|
|
10
10
|
.command("domains <action> [domainName]")
|
|
11
11
|
.description("Manage custom domains (actions: add, ls)")
|
package/src/commands/env.js
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
1
|
+
import fs from 'fs'
|
|
2
|
+
import path from 'path'
|
|
3
|
+
import chalk from 'chalk'
|
|
4
|
+
import ora from 'ora'
|
|
5
|
+
import { axios, API_BASE_URL, CONFIG_FILE } from '../config.js'
|
|
6
6
|
|
|
7
|
-
|
|
7
|
+
export default (program) => {
|
|
8
8
|
const envCommand = program
|
|
9
9
|
.command("env")
|
|
10
10
|
.description("Manage your environment variables")
|
|
@@ -33,7 +33,7 @@ module.exports = (program) => {
|
|
|
33
33
|
|
|
34
34
|
const spinner = ora("Pushing environment variables...").start()
|
|
35
35
|
try {
|
|
36
|
-
const dotenv =
|
|
36
|
+
const { default: dotenv } = await import('dotenv')
|
|
37
37
|
const envConfig = dotenv.parse(fs.readFileSync(envPath))
|
|
38
38
|
|
|
39
39
|
const envs = Object.keys(envConfig).map((key) => ({
|
package/src/commands/info.js
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
1
|
+
import fs from 'fs'
|
|
2
|
+
import path from 'path'
|
|
3
|
+
import axios from 'axios'
|
|
4
|
+
import chalk from 'chalk'
|
|
5
|
+
import ora from 'ora'
|
|
6
|
+
import { getNexforgeConfig } from '../config.js'
|
|
7
7
|
|
|
8
|
-
|
|
8
|
+
export default (program) => {
|
|
9
9
|
program
|
|
10
10
|
.command("info")
|
|
11
11
|
.description("View project info and status")
|
package/src/commands/init.js
CHANGED
|
@@ -1,14 +1,15 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
1
|
+
import readlineModule from 'readline'
|
|
2
|
+
import fs from 'fs'
|
|
3
|
+
import chalk from 'chalk'
|
|
4
|
+
import ora from 'ora'
|
|
5
|
+
import { axios, API_BASE_URL, CONFIG_DIR, CONFIG_FILE } from '../config.js'
|
|
5
6
|
|
|
6
|
-
|
|
7
|
+
export default (program) => {
|
|
7
8
|
program
|
|
8
9
|
.command("init")
|
|
9
10
|
.description("Initialize a new NexForge project in the current directory")
|
|
10
11
|
.action(async () => {
|
|
11
|
-
const readline =
|
|
12
|
+
const readline = readlineModule.createInterface({
|
|
12
13
|
input: process.stdin,
|
|
13
14
|
output: process.stdout,
|
|
14
15
|
})
|
package/src/commands/login.js
CHANGED
|
@@ -1,13 +1,14 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
1
|
+
import fs from 'fs'
|
|
2
|
+
import readlineModule from 'readline'
|
|
3
|
+
import chalk from 'chalk'
|
|
4
|
+
import { CONFIG_DIR, CONFIG_FILE } from '../config.js'
|
|
4
5
|
|
|
5
|
-
|
|
6
|
+
export default (program) => {
|
|
6
7
|
program
|
|
7
8
|
.command("login")
|
|
8
9
|
.description("Log in to your NexForge account")
|
|
9
10
|
.action(async () => {
|
|
10
|
-
const readline =
|
|
11
|
+
const readline = readlineModule.createInterface({
|
|
11
12
|
input: process.stdin,
|
|
12
13
|
output: process.stdout,
|
|
13
14
|
})
|
package/src/commands/logs.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
1
|
+
import fs from 'fs'
|
|
2
|
+
import chalk from 'chalk'
|
|
3
|
+
import { API_BASE_URL, CONFIG_FILE } from '../config.js'
|
|
4
4
|
|
|
5
|
-
|
|
5
|
+
export default (program) => {
|
|
6
6
|
program
|
|
7
7
|
.command("logs")
|
|
8
8
|
.description("Stream live build logs for your NexForge project")
|
|
@@ -25,7 +25,7 @@ module.exports = (program) => {
|
|
|
25
25
|
),
|
|
26
26
|
)
|
|
27
27
|
|
|
28
|
-
const io =
|
|
28
|
+
const { default: io } = await import('socket.io-client')
|
|
29
29
|
const socket = io(API_BASE_URL.replace("/api", ""), {
|
|
30
30
|
transports: ["websocket", "polling"],
|
|
31
31
|
})
|
package/src/commands/open.js
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
1
|
+
import fs from 'fs'
|
|
2
|
+
import path from 'path'
|
|
3
|
+
import axios from 'axios'
|
|
4
|
+
import chalk from 'chalk'
|
|
5
|
+
import ora from 'ora'
|
|
6
|
+
import { exec } from 'child_process'
|
|
7
|
+
import { getNexforgeConfig } from '../config.js'
|
|
8
8
|
|
|
9
|
-
|
|
9
|
+
export default (program) => {
|
|
10
10
|
program
|
|
11
11
|
.command("open")
|
|
12
12
|
.description("Open the live project in your browser")
|
package/src/commands/rename.js
CHANGED
|
@@ -1,14 +1,15 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
1
|
+
import readlineModule from 'readline'
|
|
2
|
+
import fs from 'fs'
|
|
3
|
+
import chalk from 'chalk'
|
|
4
|
+
import ora from 'ora'
|
|
5
|
+
import { axios, API_BASE_URL, CONFIG_DIR, CONFIG_FILE } from '../config.js'
|
|
5
6
|
|
|
6
|
-
|
|
7
|
+
export default (program) => {
|
|
7
8
|
program
|
|
8
9
|
.command("rename")
|
|
9
10
|
.description("Rename the subdomain of your project")
|
|
10
11
|
.action(async () => {
|
|
11
|
-
const readline =
|
|
12
|
+
const readline = readlineModule.createInterface({
|
|
12
13
|
input: process.stdin,
|
|
13
14
|
output: process.stdout,
|
|
14
15
|
})
|
package/src/commands/rollback.js
CHANGED
|
@@ -1,9 +1,10 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
1
|
+
import readlineModule from 'readline'
|
|
2
|
+
import fs from 'fs'
|
|
3
|
+
import chalk from 'chalk'
|
|
4
|
+
import ora from 'ora'
|
|
5
|
+
import { axios, API_BASE_URL, CONFIG_FILE } from '../config.js'
|
|
5
6
|
|
|
6
|
-
|
|
7
|
+
export default (program) => {
|
|
7
8
|
program
|
|
8
9
|
.command("rollback")
|
|
9
10
|
.description("Rollback your live website to a previous deployment")
|
|
@@ -48,7 +49,7 @@ module.exports = (program) => {
|
|
|
48
49
|
)
|
|
49
50
|
})
|
|
50
51
|
|
|
51
|
-
const readline =
|
|
52
|
+
const readline = readlineModule.createInterface({
|
|
52
53
|
input: process.stdin,
|
|
53
54
|
output: process.stdout,
|
|
54
55
|
})
|
package/src/config.js
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
1
|
+
import axios from 'axios'
|
|
2
|
+
import fs from 'fs'
|
|
3
|
+
import path from 'path'
|
|
4
|
+
import os from 'os'
|
|
5
5
|
|
|
6
|
-
const CONFIG_DIR = path.join(os.homedir(), ".nexforge")
|
|
7
|
-
const CONFIG_FILE = path.join(CONFIG_DIR, "config.json")
|
|
6
|
+
export const CONFIG_DIR = path.join(os.homedir(), ".nexforge")
|
|
7
|
+
export const CONFIG_FILE = path.join(CONFIG_DIR, "config.json")
|
|
8
8
|
|
|
9
|
-
const API_BASE_URL = "https://nexforge-lbxg.onrender.com/api"
|
|
9
|
+
export const API_BASE_URL = "https://nexforge-lbxg.onrender.com/api"
|
|
10
10
|
|
|
11
11
|
// Intercept axios requests to attach the CLI Token if it exists
|
|
12
12
|
axios.interceptors.request.use((config) => {
|
|
@@ -19,9 +19,11 @@ axios.interceptors.request.use((config) => {
|
|
|
19
19
|
return config
|
|
20
20
|
})
|
|
21
21
|
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
22
|
+
export { axios }
|
|
23
|
+
|
|
24
|
+
export const getNexforgeConfig = () => {
|
|
25
|
+
if (fs.existsSync(CONFIG_FILE)) {
|
|
26
|
+
return JSON.parse(fs.readFileSync(CONFIG_FILE, "utf8"))
|
|
27
|
+
}
|
|
28
|
+
return {}
|
|
27
29
|
}
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "backend",
|
|
3
|
+
"version": "1.0.0",
|
|
4
|
+
"main": "src/server.js",
|
|
5
|
+
"scripts": {
|
|
6
|
+
"dev": "nodemon src/server.js",
|
|
7
|
+
"start": "node src/server.js"
|
|
8
|
+
},
|
|
9
|
+
"dependencies": {
|
|
10
|
+
"@aws-sdk/client-s3": "^3.1075.0",
|
|
11
|
+
"@aws-sdk/lib-storage": "^3.1075.0",
|
|
12
|
+
"@google/genai": "^2.10.0",
|
|
13
|
+
"axios": "^1.18.0",
|
|
14
|
+
"bullmq": "^5.79.1",
|
|
15
|
+
"cookie-parser": "^1.4.7",
|
|
16
|
+
"cors": "^2.8.6",
|
|
17
|
+
"dotenv": "^17.4.2",
|
|
18
|
+
"express": "^5.2.1",
|
|
19
|
+
"express-rate-limit": "^8.5.2",
|
|
20
|
+
"extract-zip": "^2.0.1",
|
|
21
|
+
"groq-sdk": "^1.3.0",
|
|
22
|
+
"http-proxy-middleware": "^4.1.1",
|
|
23
|
+
"ioredis": "^5.11.1",
|
|
24
|
+
"jsonwebtoken": "^9.0.3",
|
|
25
|
+
"mime-types": "^3.0.2",
|
|
26
|
+
"mongoose": "^9.7.1",
|
|
27
|
+
"multer": "^2.2.0",
|
|
28
|
+
"node-cron": "^4.5.0",
|
|
29
|
+
"openai": "^6.44.0",
|
|
30
|
+
"os-utils": "^0.0.14",
|
|
31
|
+
"pm2": "^7.0.1",
|
|
32
|
+
"portfinder": "^1.0.38",
|
|
33
|
+
"redis": "^6.0.0",
|
|
34
|
+
"socket.io": "^4.8.3"
|
|
35
|
+
},
|
|
36
|
+
"devDependencies": {
|
|
37
|
+
"nodemon": "^3.1.14"
|
|
38
|
+
}
|
|
39
|
+
}
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
const express = require('express');
|
|
2
|
+
const cors = require('cors');
|
|
3
|
+
require('dotenv').config();
|
|
4
|
+
|
|
5
|
+
const app = express();
|
|
6
|
+
app.use(cors());
|
|
7
|
+
app.use(express.json());
|
|
8
|
+
|
|
9
|
+
app.get('/', (req, res) => res.send('NexForge Backend API is running!'));
|
|
10
|
+
|
|
11
|
+
const PORT = process.env.PORT || 8000;
|
|
12
|
+
app.listen(PORT, () => console.log(`Server running on port ${PORT}`));
|
|
File without changes
|
|
File without changes
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "backend",
|
|
3
|
+
"version": "1.0.0",
|
|
4
|
+
"main": "src/server.js",
|
|
5
|
+
"scripts": {
|
|
6
|
+
"dev": "nodemon src/server.js",
|
|
7
|
+
"start": "node src/server.js"
|
|
8
|
+
},
|
|
9
|
+
"dependencies": {
|
|
10
|
+
"@aws-sdk/client-s3": "^3.1075.0",
|
|
11
|
+
"@aws-sdk/lib-storage": "^3.1075.0",
|
|
12
|
+
"@google/genai": "^2.10.0",
|
|
13
|
+
"axios": "^1.18.0",
|
|
14
|
+
"bullmq": "^5.79.1",
|
|
15
|
+
"cookie-parser": "^1.4.7",
|
|
16
|
+
"cors": "^2.8.6",
|
|
17
|
+
"dotenv": "^17.4.2",
|
|
18
|
+
"express": "^5.2.1",
|
|
19
|
+
"express-rate-limit": "^8.5.2",
|
|
20
|
+
"extract-zip": "^2.0.1",
|
|
21
|
+
"groq-sdk": "^1.3.0",
|
|
22
|
+
"http-proxy-middleware": "^4.1.1",
|
|
23
|
+
"ioredis": "^5.11.1",
|
|
24
|
+
"jsonwebtoken": "^9.0.3",
|
|
25
|
+
"mime-types": "^3.0.2",
|
|
26
|
+
"multer": "^2.2.0",
|
|
27
|
+
"node-cron": "^4.5.0",
|
|
28
|
+
"openai": "^6.44.0",
|
|
29
|
+
"os-utils": "^0.0.14",
|
|
30
|
+
"pm2": "^7.0.1",
|
|
31
|
+
"portfinder": "^1.0.38",
|
|
32
|
+
"redis": "^6.0.0",
|
|
33
|
+
"socket.io": "^4.8.3",
|
|
34
|
+
"pg": "^8.11.3"
|
|
35
|
+
},
|
|
36
|
+
"devDependencies": {
|
|
37
|
+
"nodemon": "^3.1.14"
|
|
38
|
+
}
|
|
39
|
+
}
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
const express = require('express');
|
|
2
|
+
const cors = require('cors');
|
|
3
|
+
const { Client } = require('pg');
|
|
4
|
+
require('dotenv').config();
|
|
5
|
+
|
|
6
|
+
const app = express();
|
|
7
|
+
app.use(cors());
|
|
8
|
+
app.use(express.json());
|
|
9
|
+
|
|
10
|
+
// const client = new Client({ connectionString: process.env.PG_URI });
|
|
11
|
+
// client.connect();
|
|
12
|
+
|
|
13
|
+
app.get('/', (req, res) => res.send('NexForge Backend API (Postgres) is running!'));
|
|
14
|
+
|
|
15
|
+
const PORT = process.env.PORT || 8000;
|
|
16
|
+
app.listen(PORT, () => console.log(`Server running on port ${PORT}`));
|
|
File without changes
|
|
File without changes
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "backend",
|
|
3
|
+
"version": "1.0.0",
|
|
4
|
+
"main": "src/server.js",
|
|
5
|
+
"scripts": {
|
|
6
|
+
"dev": "nodemon src/server.js",
|
|
7
|
+
"start": "node src/server.js"
|
|
8
|
+
},
|
|
9
|
+
"dependencies": {
|
|
10
|
+
"@aws-sdk/client-s3": "^3.1075.0",
|
|
11
|
+
"@aws-sdk/lib-storage": "^3.1075.0",
|
|
12
|
+
"@google/genai": "^2.10.0",
|
|
13
|
+
"axios": "^1.18.0",
|
|
14
|
+
"bullmq": "^5.79.1",
|
|
15
|
+
"cookie-parser": "^1.4.7",
|
|
16
|
+
"cors": "^2.8.6",
|
|
17
|
+
"dotenv": "^17.4.2",
|
|
18
|
+
"express": "^5.2.1",
|
|
19
|
+
"express-rate-limit": "^8.5.2",
|
|
20
|
+
"extract-zip": "^2.0.1",
|
|
21
|
+
"groq-sdk": "^1.3.0",
|
|
22
|
+
"http-proxy-middleware": "^4.1.1",
|
|
23
|
+
"ioredis": "^5.11.1",
|
|
24
|
+
"jsonwebtoken": "^9.0.3",
|
|
25
|
+
"mime-types": "^3.0.2",
|
|
26
|
+
"multer": "^2.2.0",
|
|
27
|
+
"node-cron": "^4.5.0",
|
|
28
|
+
"openai": "^6.44.0",
|
|
29
|
+
"os-utils": "^0.0.14",
|
|
30
|
+
"pm2": "^7.0.1",
|
|
31
|
+
"portfinder": "^1.0.38",
|
|
32
|
+
"redis": "^6.0.0",
|
|
33
|
+
"socket.io": "^4.8.3",
|
|
34
|
+
"mysql2": "^3.9.1"
|
|
35
|
+
},
|
|
36
|
+
"devDependencies": {
|
|
37
|
+
"nodemon": "^3.1.14"
|
|
38
|
+
}
|
|
39
|
+
}
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
const express = require('express');
|
|
2
|
+
const cors = require('cors');
|
|
3
|
+
const mysql = require('mysql2/promise');
|
|
4
|
+
require('dotenv').config();
|
|
5
|
+
|
|
6
|
+
const app = express();
|
|
7
|
+
app.use(cors());
|
|
8
|
+
app.use(express.json());
|
|
9
|
+
|
|
10
|
+
// const pool = mysql.createPool(process.env.MYSQL_URI);
|
|
11
|
+
|
|
12
|
+
app.get('/', (req, res) => res.send('NexForge Backend API (MySQL) is running!'));
|
|
13
|
+
|
|
14
|
+
const PORT = process.env.PORT || 8000;
|
|
15
|
+
app.listen(PORT, () => console.log(`Server running on port ${PORT}`));
|
|
File without changes
|
|
File without changes
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
<!doctype html>
|
|
2
|
+
<html lang="en">
|
|
3
|
+
<head>
|
|
4
|
+
<meta charset="UTF-8" />
|
|
5
|
+
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
6
|
+
<title>NexForge App</title>
|
|
7
|
+
</head>
|
|
8
|
+
<body>
|
|
9
|
+
<div id="root"></div>
|
|
10
|
+
<script type="module" src="/src/main.jsx"></script>
|
|
11
|
+
</body>
|
|
12
|
+
</html>
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "frontend",
|
|
3
|
+
"private": true,
|
|
4
|
+
"version": "0.0.0",
|
|
5
|
+
"type": "module",
|
|
6
|
+
"scripts": {
|
|
7
|
+
"dev": "vite",
|
|
8
|
+
"build": "vite build",
|
|
9
|
+
"preview": "vite preview"
|
|
10
|
+
},
|
|
11
|
+
"dependencies": {
|
|
12
|
+
"@heroicons/react": "^2.2.0",
|
|
13
|
+
"axios": "^1.18.0",
|
|
14
|
+
"clsx": "^2.1.1",
|
|
15
|
+
"framer-motion": "^12.40.0",
|
|
16
|
+
"gsap": "^3.15.0",
|
|
17
|
+
"lenis": "^1.3.23",
|
|
18
|
+
"lucide-react": "^1.21.0",
|
|
19
|
+
"react-icons": "^5.6.0",
|
|
20
|
+
"react-redux": "^9.1.1",
|
|
21
|
+
"@reduxjs/toolkit": "^2.2.3",
|
|
22
|
+
"react-toastify": "^11.1.0",
|
|
23
|
+
"recharts": "^3.8.1",
|
|
24
|
+
"socket.io-client": "^4.8.3",
|
|
25
|
+
"tailwind-merge": "^3.6.0",
|
|
26
|
+
"react": "^19.2.6",
|
|
27
|
+
"react-dom": "^19.2.6",
|
|
28
|
+
"react-router-dom": "^7.18.0"
|
|
29
|
+
},
|
|
30
|
+
"devDependencies": {
|
|
31
|
+
"@vitejs/plugin-react": "^6.0.1",
|
|
32
|
+
"vite": "^8.0.12",
|
|
33
|
+
"tailwindcss": "^3.4.19",
|
|
34
|
+
"postcss": "^8.5.15",
|
|
35
|
+
"autoprefixer": "^10.5.0"
|
|
36
|
+
}
|
|
37
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export default { plugins: { tailwindcss: {}, autoprefixer: {} } }
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
<!doctype html>
|
|
2
|
+
<html lang="en">
|
|
3
|
+
<head>
|
|
4
|
+
<meta charset="UTF-8" />
|
|
5
|
+
<link rel="icon" type="image/svg+xml" href="/vite.svg" />
|
|
6
|
+
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
7
|
+
<title>NexForge Vue App</title>
|
|
8
|
+
</head>
|
|
9
|
+
<body>
|
|
10
|
+
<div id="app"></div>
|
|
11
|
+
<script type="module" src="/src/main.js"></script>
|
|
12
|
+
</body>
|
|
13
|
+
</html>
|