chore: init

This commit is contained in:
2025-10-25 22:31:06 +07:00
parent 93d98edb65
commit 3cdf5f6ba5
5 changed files with 93 additions and 2 deletions

29
.gitignore vendored Normal file
View File

@@ -0,0 +1,29 @@
# dev
.yarn/
!.yarn/releases
.vscode/*
!.vscode/launch.json
!.vscode/*.code-snippets
.idea/workspace.xml
.idea/usage.statistics.xml
.idea/shelf
# deps
node_modules/
# env
.env
.env.production
# logs
logs/
*.log
npm-debug.log*
yarn-debug.log*
yarn-error.log*
pnpm-debug.log*
lerna-debug.log*
# misc
.DS_Store
.vercel

View File

@@ -1,2 +1,27 @@
# google-play-scraper-worker
Host [google-play-scraper](https://github.com/facundoolano/google-play-scraper) on [Cloudflare Workers](https://workers.cloudflare.com)
# google-play-scraper
Host [google-play-scraper](https://github.com/facundoolano/google-play-scraper) on [Vercel](https://vercel.com)
To develop locally:
```
npm install
vc dev
```
```
open http://localhost:3000
```
To build locally:
```
npm install
vc build
```
To deploy:
```
npm install
vc deploy
```

12
package.json Normal file
View File

@@ -0,0 +1,12 @@
{
"name": "express",
"type": "module",
"dependencies": {
"express": "5.1.0"
},
"devDependencies": {
"@types/node": "20.11.17",
"@types/express": "5.0.0",
"typescript": "5.8.3"
}
}

17
src/index.ts Normal file
View File

@@ -0,0 +1,17 @@
import express from 'express'
const app = express()
app.get('/', (_req, res) => {
res.send('Hello Express!')
})
app.get('/api/users/:id', (_req, res) => {
res.json({ id: _req.params.id })
})
app.get('/api/posts/:postId/comments/:commentId', (_req, res) => {
res.json({ postId: _req.params.postId, commentId: _req.params.commentId })
})
export default app

8
tsconfig.json Normal file
View File

@@ -0,0 +1,8 @@
{
"compilerOptions": {
"target": "ESNext",
"module": "NodeNext",
"skipLibCheck": true,
},
"exclude": ["node_modules"]
}