chore: mark jsdom as external to remove warning

This commit is contained in:
Pooya Parsa 2020-02-06 14:02:05 +01:00
parent 1df1874f8a
commit 39d33686f4
3 changed files with 10 additions and 3 deletions

View File

@ -1,3 +1,6 @@
export default { export default {
build: true build: true,
rollup: {
externals: ['jsdom']
}
} }

View File

@ -189,7 +189,8 @@ export default class Package {
const config = { const config = {
rootDir: this.options.rootDir, rootDir: this.options.rootDir,
alias: {}, alias: {},
replace: {} replace: {},
...this.options.rollup
} }
// Replace linkedDependencies with their suffixed version // Replace linkedDependencies with their suffixed version

View File

@ -17,6 +17,7 @@ export default function rollupConfig ({
input = 'src/index.js', input = 'src/index.js',
replace = {}, replace = {},
alias = {}, alias = {},
externals = [],
resolve = { resolve = {
only: [ only: [
/lodash/ /lodash/
@ -43,7 +44,9 @@ export default function rollupConfig ({
// Dependencies that will be installed alongise with the nuxt package // Dependencies that will be installed alongise with the nuxt package
...Object.keys(pkg.dependencies || {}), ...Object.keys(pkg.dependencies || {}),
// Builtin node modules // Builtin node modules
...builtins ...builtins,
// Explicit externals
...externals
], ],
plugins: [ plugins: [
aliasPlugin(alias), aliasPlugin(alias),