We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 3681016 commit 1d22896Copy full SHA for 1d22896
src/server/create-bundle-renderer.js
@@ -37,7 +37,11 @@ export function createBundleRendererCreator (createRenderer: () => Renderer) {
37
let basedir = rendererOptions && rendererOptions.basedir
38
39
// load bundle if given filepath
40
- if (typeof bundle === 'string' && bundle.charAt(0) === '/') {
+ if (
41
+ typeof bundle === 'string' &&
42
+ /\.js(on)?$/.test(bundle) &&
43
+ path.isAbsolute(bundle)
44
+ ) {
45
if (fs.existsSync(bundle)) {
46
basedir = basedir || path.dirname(bundle)
47
bundle = fs.readFileSync(bundle, 'utf-8')
0 commit comments