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.

External node module css load problem

See original GitHub issue

Getting error in every external module which import css internally. Here, I am using react-flexbox-grid which import flexboxgrid.css from flexboxgrid module.

`Failed to compile.

Error in ./~/flexboxgrid/dist/flexboxgrid.css Module parse failed: /media/sam/project/node_modules/flexboxgrid/dist/flexboxgrid.css Unexpected token (1:0) You may need an appropriate loader to handle this file type. SyntaxError: Unexpected token (1:0) `

Issue Analytics

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

github_iconTop GitHub Comments

1reaction
gaearoncommented, Aug 7, 2016

No, style!css!postcss does not mean support for CSS Modules. Only css?modules would enable them.

As for the code you’re referring to, it is from an old version on Create React App. Have you updated to 0.2.1? node_modules is included for CSS loader just fine there (but not CSS modules).

0reactions
sphingucommented, Aug 8, 2016

thanks for the explanation. currently, I am using 0.1.0 version.

Read more comments on GitHub >

github_iconTop Results From Across the Web

load css in node_modules fail on server in some cases #1070
The problem I can think of is that it's not using postcss-loader for node by looking at the razzle/config/createConfig.js for css rules.
Read more >
Unable to load css from node modules package - Stack Overflow
I am trying to import css from node modules package. import "packageName/dist/index.bundle.css";. I get the error "currently no loaders are ...
Read more >
css-loader | webpack - JS.ORG
npm install --save-dev css-loader · yarn add -D css-loader · pnpm add -D css-loader · import css from "file.css"; · module.exports = {...
Read more >
CSS and JS not loading – node.js and Express - YouTube
This video is the part of this bloghttps://www.tipspot.xyz/ css -and- js - not-loading - node - js -and-express.
Read more >
Basic Features: Built-in CSS Support - Next.js
This behavior makes CSS Modules the ideal way to include component-level CSS. CSS Module files can be imported anywhere in your application.
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