Skip to content

Commit

Permalink
feat: Add tsconfig plugin ts-transformer-imports to combile
Browse files Browse the repository at this point in the history
ts source with mapped path
  • Loading branch information
ashchan committed Aug 4, 2019
1 parent 845feff commit bb9cedf
Show file tree
Hide file tree
Showing 3 changed files with 43 additions and 4 deletions.
6 changes: 4 additions & 2 deletions packages/neuron-wallet/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
"scripts": {
"start": "electron .",
"start:dev": "yarn run build && electron .",
"build": "tsc && ncp ./src/startup/sync-block-task/index.html ./dist/startup/sync-block-task/index.html",
"build": "ttsc && ncp ./src/startup/sync-block-task/index.html ./dist/startup/sync-block-task/index.html",
"clean": "rimraf dist/*",
"test": "jest --color",
"test:e2e": "jest --config jest.e2e.config.js --color",
Expand Down Expand Up @@ -64,6 +64,8 @@
"lint-staged": "9.2.0",
"neuron-ui": "0.17.0-alpha.5",
"rimraf": "2.6.3",
"spectron": "7.0.0"
"spectron": "7.0.0",
"ts-transformer-imports": "^0.4.3",
"ttypescript": "^1.5.7"
}
}
6 changes: 4 additions & 2 deletions packages/neuron-wallet/tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,14 @@
"sourceMap": true,
"declaration": true,
"emitDecoratorMetadata": true,
"noEmit": true,
"outDir": "dist",
"baseUrl": ".",
"paths": {
"*": ["./src/*", "node_modules/*"]
}
},
"plugins": [
{ "transform": "ts-transformer-imports" }
]
},
"include": ["src/**/*"]
}
35 changes: 35 additions & 0 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -3115,6 +3115,11 @@
dependencies:
"@types/jest-diff" "*"

"@types/json5@^0.0.29":
version "0.0.29"
resolved "https://registry.yarnpkg.com/@types/json5/-/json5-0.0.29.tgz#ee28707ae94e11d2b827bcbe5270bcea7f3e71ee"
integrity sha1-7ihweulOEdK4J7y+UnC86n8+ce4=

"@types/minimatch@*":
version "3.0.3"
resolved "https://registry.yarnpkg.com/@types/minimatch/-/minimatch-3.0.3.tgz#3dca0e3f33b200fc7d1139c0cd96c1268cadfd9d"
Expand Down Expand Up @@ -6680,6 +6685,11 @@ [email protected]:
resolved "https://registry.yarnpkg.com/deepmerge/-/deepmerge-3.2.1.tgz#76a1f47854bcfcd66ee9a948d110540a8e12b261"
integrity sha512-+hbDSzTqEW0fWgnlKksg7XAOtT+ddZS5lHZJ6f6MdixRs9wQy+50fm1uUCVb1IkvjLUYX/SfFO021ZNwriURTw==

deepmerge@^2.0.1:
version "2.2.1"
resolved "https://registry.yarnpkg.com/deepmerge/-/deepmerge-2.2.1.tgz#5d3ff22a01c00f645405a2fbc17d0778a1801170"
integrity sha512-R9hc1Xa/NOBi9WRVUWg19rl1UB7Tt4kuPd+thNJgFZoxXsTz7ncaPaeIm+40oSGuP33DfMb4sZt1QIGiJzC4EA==

deepmerge@~2.0.1:
version "2.0.1"
resolved "https://registry.yarnpkg.com/deepmerge/-/deepmerge-2.0.1.tgz#25c1c24f110fb914f80001b925264dd77f3f4312"
Expand Down Expand Up @@ -16691,6 +16701,24 @@ [email protected], ts-pnp@^1.0.0, ts-pnp@^1.1.2:
resolved "https://registry.yarnpkg.com/ts-pnp/-/ts-pnp-1.1.2.tgz#be8e4bfce5d00f0f58e0666a82260c34a57af552"
integrity sha512-f5Knjh7XCyRIzoC/z1Su1yLLRrPrFCgtUAh/9fCSP6NKbATwpOL1+idQVXQokK9GRFURn/jYPGPfegIctwunoA==

ts-transformer-imports@^0.4.3:
version "0.4.3"
resolved "https://registry.yarnpkg.com/ts-transformer-imports/-/ts-transformer-imports-0.4.3.tgz#d1527978cae552af9f821b06cc2233cdf2e09e42"
integrity sha512-Dy9f42DwDucTu1HhkyTTyd+LcVmhHTNN9n0Q9yMYwT40qpUESl/MCn7Q4rj6uIgSrC3y1MWVlWR9k5ba6EaG7w==
dependencies:
tsconfig-paths "^3.6.0"

tsconfig-paths@^3.6.0:
version "3.8.0"
resolved "https://registry.yarnpkg.com/tsconfig-paths/-/tsconfig-paths-3.8.0.tgz#4e34202d5b41958f269cf56b01ed95b853d59f72"
integrity sha512-zZEYFo4sjORK8W58ENkRn9s+HmQFkkwydDG7My5s/fnfr2YYCaiyXe/HBUcIgU8epEKOXwiahOO+KZYjiXlWyQ==
dependencies:
"@types/json5" "^0.0.29"
deepmerge "^2.0.1"
json5 "^1.0.1"
minimist "^1.2.0"
strip-bom "^3.0.0"

tslib@^1.7.1, tslib@^1.8.1, tslib@^1.9.0:
version "1.10.0"
resolved "https://registry.yarnpkg.com/tslib/-/tslib-1.10.0.tgz#c3c19f95973fb0a62973fb09d90d961ee43e5c8a"
Expand All @@ -16708,6 +16736,13 @@ [email protected]:
resolved "https://registry.yarnpkg.com/tty-browserify/-/tty-browserify-0.0.0.tgz#a157ba402da24e9bf957f9aa69d524eed42901a6"
integrity sha1-oVe6QC2iTpv5V/mqadUk7tQpAaY=

ttypescript@^1.5.7:
version "1.5.7"
resolved "https://registry.yarnpkg.com/ttypescript/-/ttypescript-1.5.7.tgz#76bb96765b331194b58a4e7d79fae82b886fc29a"
integrity sha512-qloW8S60+xWVC2bQWldYQfESNFkIgDL5/M+vAOOsuLJ1pQu0SG2vQx5DNJO2nlwSrHxD8cDuF2sVDXg6v3GG3Q==
dependencies:
resolve "^1.9.0"

tunnel-agent@^0.6.0:
version "0.6.0"
resolved "https://registry.yarnpkg.com/tunnel-agent/-/tunnel-agent-0.6.0.tgz#27a5dea06b36b04a0a9966774b290868f0fc40fd"
Expand Down

0 comments on commit bb9cedf

Please sign in to comment.