Updates webpack config to use "this" over "window" in generated files. This allows the generated files in dist to be usable in both browsers and Node.js.
Previously, some server-side environments could generate "window is not defined" errors as a result of requiring the dist files bundled with prismic-dom, since the webpack-generated dist files referenced window specifically, which is usually only defined in browser environments.
Updates webpack config to use "
this
" over "window
" in generated files. This allows the generated files indist
to be usable in both browsers and Node.js.Previously, some server-side environments could generate "window is not defined" errors as a result of requiring the dist files bundled with prismic-dom, since the webpack-generated dist files referenced window specifically, which is usually only defined in browser environments.