question-mark
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.

Build breaks with webpack 2, postcss and svg-inline

See original GitHub issue

I’m submitting a bug report

Webpack version: 2.x

Please tell us about your environment: OSX 10.x

Current behavior: With a specific file structure and when using postcss-loader, postcss-import and svg-inline-loader, I get the following error:

Module build failed: (SystemJS) ENOENT: no such file or directory, open '/Users/karolis/webpack-2-failing-build/loader-utils'

Expected/desired behavior: The build should work.

To reproduce

  1. Clone https://github.com/KidkArolis/webpack-2-failing-build
  2. Run npm install && webpack --progress

I think the bug itself is caused by postcss-import, but this only happens in webpack@2, so I thought I’ll post here first and cross link to postcss-import repo. It would be nice to dive deeper and understand what’s causing this issue. It only seems to be happening with this very specific file structure. Moving the .css file around for example, might cause the build to work again. Any pointers on how to debug this further would also be appreciated.

Issue Analytics

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

github_iconTop GitHub Comments

3reactions
Jessidhiacommented, Aug 22, 2016

Yep, postcss-import somehow breaks webpack’s module resolution. It may be a bug with webpack’s SystemJS support, but for now the workaround is to pin postcss-import to 8.1.0.

0reactions
webpack-botcommented, Aug 26, 2017

Issue was closed because of inactivity.

If you think this is still a valid issue, please file a new issue with additional information.

Read more comments on GitHub >

github_iconTop Results From Across the Web

postcss-loader | webpack - JS.ORG
webpack is a module bundler. Its main purpose is to bundle JavaScript files for usage in a browser, yet it is also capable...
Read more >
Storybook - GitHub Pages
[Breaking] Icons are now aligned to the text baseline out of the box (only when using the following icon sizes: 10px, 14px, 16px,...
Read more >
Having a prod build issue with Webpack, React, postCSS, and ...
Either that or my JS is broken and not building the page properly. Not in my production build (same build it does when...
Read more >
Build Performance - webpack
This guide contains some useful tips for improving build/compilation ... Newer versions create more efficient module trees and increase resolving speed.
Read more >
postcss-loader - webpack 3 documentation
Loader for webpack to process CSS with PostCSS ... style.css (2) | |– postcss.config.js (1 && 2 (recommended)) |– webpack.config.js | |– package.json....
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 Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found