Skip to content

Commit

Permalink
fix(babel): depend on buffer package in es build
Browse files Browse the repository at this point in the history
  • Loading branch information
davidyuk committed Jan 27, 2022
1 parent c45a6f8 commit 9b0f3dc
Show file tree
Hide file tree
Showing 5 changed files with 23 additions and 2 deletions.
3 changes: 3 additions & 0 deletions babel.esm.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,9 @@ config.presets

config.plugins.push(
['add-import-extension', { extension: 'mjs' }],
['import-globals', {
Buffer: { moduleName: 'buffer', exportName: 'Buffer' }
}],
['transform-default-named-imports', { exclude: ['rlp'] }]
)

Expand Down
1 change: 0 additions & 1 deletion examples/browser/aepp/vue.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ const config = require('../../../webpack.config')
const sdkWebpackConfig = config[1]({}, {})

module.exports = defineConfig({
transpileDependencies: true,
devServer: {
port: 9001
},
Expand Down
1 change: 0 additions & 1 deletion examples/browser/wallet-iframe/vue.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ const config = require('../../../webpack.config')
const sdkWebpackConfig = config[1]({}, {})

module.exports = defineConfig({
transpileDependencies: true,
devServer: {
port: 9000
},
Expand Down
19 changes: 19 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,7 @@
"@typescript-eslint/parser": "^5.10.1",
"babel-loader": "^8.2.3",
"babel-plugin-add-import-extension": "^1.6.0",
"babel-plugin-import-globals": "^2.0.0",
"babel-plugin-transform-default-named-imports": "^1.2.2",
"chai": "^4.3.4",
"chai-as-promised": "^7.1.1",
Expand Down

0 comments on commit 9b0f3dc

Please sign in to comment.