Skip to content

Module not found. attempted require... #16

Closed
@RylanH

Description

@RylanH

I get an error when using prerender-loader. It seems to fail with the below error. I traced it to this line and it appears that the only keys in compilation.assets are ssr-bundle.js. Any suggestions?

 '  Error: Child compilation failed:\n  Module build failed (from ./node_modules/prerender-loader/dist/prerender-loader.js):\n  Error: Error:  Module not found. attempted require("url")\n  \n  - index.js:190 runChildCompiler.then.window.require\n    [account-web]/[prerender-loader]/src/index.js:190:19\n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  - Error: Error:  Module not found. attempted require("url")\n  \n  - compiler.js:79 childCompiler.runAsChild\n    [account-web]/[react-app]/[html-webpack-plugin]/lib/compiler.js:79:16\n  \n  - Compiler.js:296 compile\n    [account-web]/[react-app]/[webpack]/lib/Compiler.js:296:11\n  \n  - Compiler.js:553 hooks.afterCompile.callAsync.err\n    [account-web]/[react-app]/[webpack]/lib/Compiler.js:553:14\n  \n  \n  - Hook.js:35 AsyncSeriesHook.lazyCompileHook [as _callAsync]\n    [account-web]/[react-app]/[tapable]/lib/Hook.js:35:21\n  \n  - Compiler.js:550 compilation.seal.err\n    [account-web]/[react-app]/[webpack]/lib/Compiler.js:550:30\n  \n  \n  - Hook.js:35 AsyncSeriesHook.lazyCompileHook [as _callAsync]\n    [account-web]/[react-app]/[tapable]/lib/Hook.js:35:21\n  \n  - Compilation.js:1294 hooks.optimizeAssets.callAsync.err\n    [account-web]/[react-app]/[webpack]/lib/Compilation.js:1294:35\n  \n  \n  - Hook.js:35 AsyncSeriesHook.lazyCompileHook [as _callAsync]\n    [account-web]/[react-app]/[tapable]/lib/Hook.js:35:21\n  \n  - Compilation.js:1285 hooks.optimizeChunkAssets.callAsync.err\n    [account-web]/[react-app]/[webpack]/lib/Compilation.js:1285:32\n  \n  \n  - Hook.js:35 AsyncSeriesHook.lazyCompileHook [as _callAsync]\n    [account-web]/[react-app]/[tapable]/lib/Hook.js:35:21\n  \n  - Compilation.js:1280 hooks.additionalAssets.callAsync.err\n    [account-web]/[react-app]/[webpack]/lib/Compilation.js:1280:36\n  \n  \n' ]

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions