Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

_webpackIsomorphicTools2.default.assets is not a function and missing path with webpack-isomorphic-tools.assets()

See original GitHub issue

I’m having a bit of trouble getting my SSR working with webpack-isomorphic-tools, so far I’ve got my build script spitting out the relevant static files and the webpack-assets.json, but on loading the server and trying to pull in the CSS using WebpackIsomorphicTools.assets() I get an error:

TypeError: _webpackIsomorphicTools2.default.assets is not a function
    at web-app/src/server/server.js:35:40

and when trying to use global.webpack_isomorphic_tools.assets() I get the error:

AssertionError: missing path
    at Module.require (module.js:466:3)
    at require (internal/module.js:20:19)
    at webpack_isomorphic_tools.assets (web-app/node_modules/webpack-isomorphic-tools/source/index.js:100:10)
    at web-app/src/server/server.js:35:49

node 6.3.1 npm 3.10.6 babel-core 6.10.4

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Comments:8 (5 by maintainers)

github_iconTop GitHub Comments

catamphetaminecommented, Oct 12, 2016

It’s a tricky one to get paths right. The code snippet you posted should be working.

ChazUKcommented, Oct 12, 2016

Quick Q whilst I’m here, any idea why app.use('/static', express.static(path.join(__dirname, 'build/static'))); doesn’t appear to be loading any static files?

Read more comments on GitHub >

github_iconTop Results From Across the Web

[webpack-isomorphic-tools] [error] asset not found #106 - GitHub
Using a default one . [webpack-isomorphic-tools/plugin] [debug] No path parser specified for "fonts" assets. Using a defaul t one.
Read more >
Integrating with webpack-isomorphic-tools - Stack Overflow
Turns out extract text plugin causes the asset not found errors, which is normal, since the asset is loaded in bundle.css , plus...
Read more >
Fixed Assets CS: Clients missing or not listed on Open Client ...
If the client is still not available follow the steps below. Close the Open Client dialog. Choose Help > Repair and click the...
Read more >
asset.getUrl() not correct: missing subfolder directory
I created a new asset source/folder called "my-assets". It has an entry in the DB in "craft_assetsources" with the id=10, path="my_base_folder/ ...
Read more >
Simple Asset Helper Functions | CSS-Tricks
should not include trailing slash /// @access public /// @type String $asset-base-path: '../assets' !default; /// Asset URL builder ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Post

No results found

github_iconTop Related Hashnode Post

No results found