#1247 fix "window is not defined" with ssr
This commit is contained in:
parent
7e01f9be6e
commit
6f450272b8
|
@ -50,7 +50,8 @@ export const jsConfig = () => {
|
||||||
filename: '[name].js',
|
filename: '[name].js',
|
||||||
library: 'mermaid',
|
library: 'mermaid',
|
||||||
libraryTarget: 'umd',
|
libraryTarget: 'umd',
|
||||||
libraryExport: 'default'
|
libraryExport: 'default',
|
||||||
|
globalObject: 'typeof self !== "undefined" ? self : this'
|
||||||
},
|
},
|
||||||
module: {
|
module: {
|
||||||
rules: [amdRule, jsRule, scssRule, jisonRule]
|
rules: [amdRule, jsRule, scssRule, jisonRule]
|
||||||
|
|
Loading…
Reference in New Issue