-
Notifications
You must be signed in to change notification settings - Fork 412
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore: run server:dev use node instead of vercel (#2933)
- Loading branch information
Showing
7 changed files
with
71 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
LEAN_ID=<Your LeanCloud ID> | ||
LEAN_KEY=<Your LeanCloud Key> | ||
LEAN_MASTER_KEY=<Your LeanCloud Master Key> | ||
LEAN_SERVER=<Your LeanCloud Server> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
const path = require('node:path'); | ||
|
||
require('dotenv').config({ | ||
path: path.join(__dirname, '../../.env'), | ||
}); | ||
|
||
const watcher = require('think-watcher'); | ||
const Application = require('thinkjs'); | ||
|
||
const instance = new Application({ | ||
ROOT_PATH: __dirname, | ||
APP_PATH: path.join(__dirname, 'src'), | ||
proxy: false, | ||
watcher: watcher, | ||
env: 'development', | ||
}); | ||
|
||
instance.run(); | ||
|
||
let config = {}; | ||
|
||
try { | ||
config = require('./config.js'); | ||
} catch { | ||
// do nothing | ||
} | ||
for (const k in config) { | ||
think.config(k, config[k]); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -14,6 +14,9 @@ | |
}, | ||
"license": "MIT", | ||
"author": "lizheming <[email protected]>", | ||
"scripts": { | ||
"dev": "node development.js 9090" | ||
}, | ||
"dependencies": { | ||
"@cloudbase/node-sdk": "^3.4.0", | ||
"@koa/cors": "^5.0.0", | ||
|
@@ -51,8 +54,12 @@ | |
"thinkjs": "^3.2.15", | ||
"ua-parser-js": "^2.0.0" | ||
}, | ||
"devDependencies": { | ||
"dotenv": "^16.4.7", | ||
"think-watcher": "^3.0.4" | ||
}, | ||
"engines": { | ||
"node": ">=16" | ||
"node": ">=20" | ||
}, | ||
"publishConfig": { | ||
"provenance": true | ||
|
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.