Add sourcemap-loader to build step (#535)
* Add sourcemap-loader to build step * .
This commit is contained in:
parent
dd1fb73876
commit
0ff6f0628f
4 changed files with 11994 additions and 11422 deletions
|
@ -46,6 +46,12 @@ module.exports = withPWA(
|
|||
})
|
||||
)
|
||||
|
||||
config.module.rules.push({
|
||||
test: /.*packages.*\.js$/,
|
||||
use: ['source-map-loader'],
|
||||
enforce: 'pre',
|
||||
})
|
||||
|
||||
if (
|
||||
SENTRY_DSN &&
|
||||
SENTRY_ORG &&
|
||||
|
|
|
@ -67,6 +67,7 @@
|
|||
"prettier": "^2.4.1",
|
||||
"pretty-quick": "^3.1.2",
|
||||
"resize-observer-polyfill": "^1.5.1",
|
||||
"source-map-loader": "^3.0.1",
|
||||
"tslib": "^2.3.0",
|
||||
"typedoc": "^0.22.3",
|
||||
"typescript": "^4.5.2"
|
||||
|
|
|
@ -28,6 +28,7 @@ async function main() {
|
|||
tsconfig: './tsconfig.json',
|
||||
external: Object.keys(pkg.dependencies).concat(Object.keys(pkg.peerDependencies)),
|
||||
metafile: true,
|
||||
sourcemap: true,
|
||||
})
|
||||
|
||||
const esmResult = esbuild.buildSync({
|
||||
|
@ -42,6 +43,7 @@ async function main() {
|
|||
jsxFragment: 'React.Fragment',
|
||||
external: Object.keys(pkg.dependencies).concat(Object.keys(pkg.peerDependencies)),
|
||||
metafile: true,
|
||||
sourcemap: true,
|
||||
})
|
||||
|
||||
const esmSize = Object.values(esmResult.metafile.outputs).reduce(
|
||||
|
|
Loading…
Reference in a new issue