|
13 | 13 | "lib"
|
14 | 14 | ],
|
15 | 15 | "scripts": {
|
16 |
| - "test": "jest --config jestconfig.json --coverage", |
17 |
| - "prepare": "npm run build", |
| 16 | + "test": "vitest --coverage --coverage.include src", |
| 17 | + "prepare": "husky", |
18 | 18 | "dev": "wrangler dev",
|
19 |
| - "build:worker": "esbuild src/cloudflare-worker/index.ts --outfile=dist/worker.js --bundle --minify --format=esm --loader:.html=text --external:events --keep-names", |
20 |
| - "build:package": "esbuild src/core/index.ts --outfile=lib/index.js --bundle --format=esm --external:events --keep-names", |
| 19 | + "build:worker": "esbuild src/cloudflare-worker/index.ts --outfile=dist/worker.js --bundle --minify --format=esm --loader:.html=text --keep-names", |
| 20 | + "build:package": "esbuild src/core/index.ts --outfile=lib/index.js --bundle --format=esm --keep-names", |
| 21 | + "build:image": "selflare compile --script dist/worker.js && docker compose build", |
21 | 22 | "build": "npm run build:worker && npm run build:package",
|
22 | 23 | "format": "prettier --write . --ignore-path .gitignore",
|
23 | 24 | "lint": "eslint .",
|
24 |
| - "push": "wrangler publish" |
| 25 | + "push": "wrangler deploy" |
25 | 26 | },
|
26 | 27 | "keywords": [
|
27 | 28 | "leetcode",
|
28 | 29 | "stats",
|
29 | 30 | "card"
|
30 | 31 | ],
|
31 |
| - "eslintConfig": { |
32 |
| - "root": true, |
33 |
| - "extends": [ |
34 |
| - "typescript", |
35 |
| - "prettier" |
36 |
| - ], |
37 |
| - "ignorePatterns": [ |
38 |
| - "dist/**.js", |
39 |
| - "lib/**.js" |
40 |
| - ] |
41 |
| - }, |
42 | 32 | "dependencies": {
|
43 |
| - "itty-router": "3.0.11", |
44 |
| - "leetcode-query": "0.2.7", |
| 33 | + "itty-router": "4.0.27", |
| 34 | + "leetcode-query": "1.0.0", |
45 | 35 | "nano-font": "0.3.1"
|
46 | 36 | },
|
47 | 37 | "devDependencies": {
|
48 |
| - "@cloudflare/workers-types": "^4.20230404.0", |
49 |
| - "@trivago/prettier-plugin-sort-imports": "^4.1.1", |
50 |
| - "@types/jest": "29.5.0", |
51 |
| - "@types/node": "^18.15.11", |
52 |
| - "@typescript-eslint/eslint-plugin": "^5.57.1", |
53 |
| - "@typescript-eslint/parser": "^5.57.1", |
54 |
| - "esbuild": "^0.15.18", |
55 |
| - "eslint": "^8.38.0", |
56 |
| - "eslint-config-prettier": "^8.8.0", |
57 |
| - "jest": "29.5.0", |
58 |
| - "prettier": "^2.8.7", |
59 |
| - "ts-jest": "29.1.0", |
60 |
| - "tsup": "6.7.0", |
61 |
| - "typescript": "^5.0.4", |
62 |
| - "wrangler": "^2.14.0" |
| 38 | + "@cloudflare/workers-types": "^4.20240222.0", |
| 39 | + "@eslint/js": "^8.57.0", |
| 40 | + "@types/node": "^20.11.24", |
| 41 | + "@typescript-eslint/eslint-plugin": "^7.1.0", |
| 42 | + "@typescript-eslint/parser": "^7.1.0", |
| 43 | + "@vitest/coverage-v8": "^1.3.1", |
| 44 | + "esbuild": "^0.20.1", |
| 45 | + "eslint": "^8.57.0", |
| 46 | + "eslint-config-prettier": "^9.1.0", |
| 47 | + "husky": "^9.0.11", |
| 48 | + "lint-staged": "^15.2.2", |
| 49 | + "prettier": "^3.2.5", |
| 50 | + "prettier-plugin-organize-imports": "^3.2.4", |
| 51 | + "selflare": "^1.0.0", |
| 52 | + "tsup": "8.0.2", |
| 53 | + "typescript": "^5.3.3", |
| 54 | + "typescript-eslint": "^7.1.0", |
| 55 | + "vitest": "^1.3.1", |
| 56 | + "wrangler": "^3.30.1" |
63 | 57 | },
|
64 | 58 | "repository": {
|
65 | 59 | "type": "git",
|
|
69 | 63 | "url": "https://github.com/JacobLinCool/LeetCode-Stats-Card/issues"
|
70 | 64 | },
|
71 | 65 | "homepage": "https://github.com/JacobLinCool/LeetCode-Stats-Card#readme",
|
72 |
| - "packageManager": "[email protected]" |
| 66 | + "packageManager": "[email protected]", |
| 67 | + "lint-staged": { |
| 68 | + "*.{js,ts}": [ |
| 69 | + "eslint --fix", |
| 70 | + "prettier --write" |
| 71 | + ] |
| 72 | + } |
73 | 73 | }
|
0 commit comments