Skip to content

Commit 205b81b

Browse files
committed
chore(script): build and format
1 parent e1801be commit 205b81b

File tree

3 files changed

+31
-1
lines changed

3 files changed

+31
-1
lines changed

package.json

+6-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,10 @@
44
"description": "A Vue composition utilities for Axios.",
55
"main": "index.js",
66
"scripts": {
7-
"test": "echo \"Error: no test specified\" && exit 1"
7+
"build": "rm -rf ./lib/* ./esm/* && yarn build:cjs && yarn build:es",
8+
"build:cjs": "tsc",
9+
"build:es": "tsc -m ESNext --outDir ./esm",
10+
"format": "prettier --write '**/*' --config ./.prettierrc"
811
},
912
"author": "wangcch <wangcch.cc@gmail.com>",
1013
"license": "MIT",
@@ -13,6 +16,8 @@
1316
},
1417
"devDependencies": {
1518
"axios": "^1.3.4",
19+
"prettier": "^2.8.4",
20+
"typescript": "^4.9.5",
1621
"vue": "^3.2.47"
1722
}
1823
}

tsconfig.json

+15
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
{
2+
"compilerOptions": {
3+
"skipLibCheck": true,
4+
"moduleResolution": "node",
5+
"target": "es5",
6+
"module": "commonjs",
7+
"esModuleInterop": true,
8+
"strict": true,
9+
"jsx": "react",
10+
"lib": ["dom", "es5", "es2015"],
11+
"outDir": "./lib",
12+
"declaration": true
13+
},
14+
"include": ["src/**/*"]
15+
}

yarn.lock

+10
Original file line numberDiff line numberDiff line change
@@ -185,6 +185,11 @@ postcss@^8.1.10:
185185
picocolors "^1.0.0"
186186
source-map-js "^1.0.2"
187187

188+
prettier@^2.8.4:
189+
version "2.8.4"
190+
resolved "https://registry.yarnpkg.com/prettier/-/prettier-2.8.4.tgz#34dd2595629bfbb79d344ac4a91ff948694463c3"
191+
integrity sha512-vIS4Rlc2FNh0BySk3Wkd6xmwxB0FpOndW5fisM5H8hsZSxU2VWVB5CWIkIjWvrHjIhxk2g3bfMKM87zNTrZddw==
192+
188193
proxy-from-env@^1.1.0:
189194
version "1.1.0"
190195
resolved "https://registry.yarnpkg.com/proxy-from-env/-/proxy-from-env-1.1.0.tgz#e102f16ca355424865755d2c9e8ea4f24d58c3e2"
@@ -205,6 +210,11 @@ sourcemap-codec@^1.4.8:
205210
resolved "https://registry.yarnpkg.com/sourcemap-codec/-/sourcemap-codec-1.4.8.tgz#ea804bd94857402e6992d05a38ef1ae35a9ab4c4"
206211
integrity sha512-9NykojV5Uih4lgo5So5dtw+f0JgJX30KCNI8gwhz2J9A15wD0Ml6tjHKwf6fTSa6fAdVBdZeNOs9eJ71qCk8vA==
207212

213+
typescript@^4.9.5:
214+
version "4.9.5"
215+
resolved "https://registry.yarnpkg.com/typescript/-/typescript-4.9.5.tgz#095979f9bcc0d09da324d58d03ce8f8374cbe65a"
216+
integrity sha512-1FXk9E2Hm+QzZQ7z+McJiHL4NW1F2EzMu9Nq9i3zAaGqibafqYwCVU6WyWAuyQRRzOlxou8xZSyXLEN8oKj24g==
217+
208218
vue@^3.2.47:
209219
version "3.2.47"
210220
resolved "https://registry.yarnpkg.com/vue/-/vue-3.2.47.tgz#3eb736cbc606fc87038dbba6a154707c8a34cff0"

0 commit comments

Comments
 (0)