Skip to content

Commit

Permalink
🐳 chore(utils): 尝试实现基于 tsconfig.json 的配置实现的typescript文件部署,目前没有实现出来。先试…
Browse files Browse the repository at this point in the history
…试tsup打包。
  • Loading branch information
ruan-cat committed Oct 18, 2024
1 parent 3677950 commit 9facbf4
Show file tree
Hide file tree
Showing 2 changed files with 27 additions and 0 deletions.
1 change: 1 addition & 0 deletions utils/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@
"generate:type-2": "tsc -p tsconfig.json --composite false --declaration true --emitDeclarationOnly true",
"generate:type-3": "vue-tsc -p tsconfig.types.json",
"get-type": "pnpm clean:type && pnpm generate:type-3",
"build:-try-1": "pnpm clean:type && vue-tsc -p tsconfig.build.json",
"rm:node_modules": "rimraf node_modules"
},
"exports": {
Expand Down
26 changes: 26 additions & 0 deletions utils/tsconfig.build.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
{
// 打包成js的配置
// https://segmentfault.com/a/1190000044599569
"extends": [
// "./tsconfig.json"
],
"compilerOptions": {
// 项目的根目录
"rootDir": ".",
// 项目基础目录
"baseUrl": "./src",
// tsc 编译产物输出目录
"outDir": "dist",
"target": "ES2015",
"module": "commonjs",
// 模块解析策略
// "moduleResolution": "ESNext",
"composite": false,
"declaration": true,
"noEmit": false,
"emitDeclarationOnly": false,
"declarationMap": true,
"allowJs": true,
// "allowImportingTsExtensions": true
},
}

0 comments on commit 9facbf4

Please sign in to comment.