Deleting outDir breaks Linaria for good
See original GitHub issueDo you want to request a feature or report a bug?
Bug.
What is the current behavior?
I sometimes see stale generated stylesheets (more on that perhaps in future issues), so I find myself deleting ./src/.linaria-cache
(my outDir
) to try to start fresh. After I do this, Linaria fails to build, spewing a bunch of errors like:
`Error in ./src/ui/components/chrome/SiteServicesMenu.js
Module not found: [CaseSensitivePathsPlugin] `src/.linaria-cache/src/ui/components/chrome/SiteServicesMenu.css` does not match the corresponding path on disk - File does not exist.
**If the current behavior is a bug, please provide the steps to reproduce and a minimal repository on GitHub that we can `yarn install` and `yarn test`.**
Restarting Webpack or clearing the Babel cache does not help. I’m stuck.
What is the expected behavior?
Missing output files get rebuilt instead of throwing errors.
Please provide your exact Babel configuration and mention your Linaria, Node, Yarn/npm version and operating system.
This is with create-react-app
, Node 8.9.0, Webpack 1.14.0, Babel 6.2.7. This is how I configured Babel:
{
"presets": [
"react-app",
[
"linaria/babel",
{
"outDir": "./src/.linaria-cache"
}
]
]
}
Issue Analytics
- State:
- Created 6 years ago
- Comments:18 (11 by maintainers)
Top Results From Across the Web
Untitled
The flintstones hollyrock a bye baby soundtrack, Best short haired dogs, ... Linaria vulgaris control, Marque pas cher gucci, Manfaat kayu rengas, ...
Read more >Untitled
Kopf an kopf silly download, Team crafted break up ssundee, Gothic shoulder wing, Adenya alanya yorum, Familia comprando dibujo, Specialized hardrock 26, ...
Read more >A fitting landing pad as I return to FINALLY purchase my first ...
I'm currently using mine for exploration and I'm loving it. Did some mining with it as well. have yet to try out combat...
Read more >Untitled
Tour 2013 one direction wikipedia, Good neck designs for salwar kameez, Kraig kleeman ... Kriegerinnen outfit, Tmjh bell schedule, Melkor and sauron slash, ......
Read more >Literature / Wandering Witch: The Journey of Elaina - TV Tropes
While he's not exactly a nice guy in the light novel either, he doesn't leer at Elaina the moment he saw her and...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
We just didn’t encounter this in our testing, but that’s definitely something buggy which we need to fix. Other than that, building the project doesn’t mean you need to run in production mode, it’s all good with dev (which should be optimised for speed, so no minification et. al.). What’s important here is to get all files processed by Babel (which runs Linaria). You can also try
cache: false
in the preset options: https://github.com/callstack/linaria/blob/master/docs/BABEL_PRESET.md#options because it might be relatedWe released Webpack loader in
0.5.0
. It should solve all of your problems, so please git a try. I’m going to close this issue. Should you have any problem, feel free to reopen it or create a new one.