Comments (16)
GatsbyJS is now supporting typescript plugin, but.. it pushes into the after of the user plugins. As a result, the linaria plugin runs before the typescript loader is attached.
If the user explicitly sets the typescript plugin above it will work, but I need to find a better way.
from gatsby-plugin-linaria.
🎉 Thank you, it does!
from gatsby-plugin-linaria.
I've just updated everything and got the same error using v1.1.3. With v1.1.2 and v1.1.1, everything works fine. I don't use typescript. I rechecked on a blank project before posting and got the same error.
from gatsby-plugin-linaria.
Well, isn't hacking webpack configs fun… I'll check it out.
from gatsby-plugin-linaria.
@guandjoy ok, both should now work in v1.1.4.
from gatsby-plugin-linaria.
@silvenon Thank you!
from gatsby-plugin-linaria.
This would be working after #18 merged.
from gatsby-plugin-linaria.
Published in v1.2.2 🚀
from gatsby-plugin-linaria.
This issue has resurfaced now that Gatsby supports Typescript out of the box. The TS check doesn't evaluate properly anymore as the internal plugin doesn't seem to add the resolvers in the same way.
from gatsby-plugin-linaria.
Ah, I almost forgot about it. I will follow up on this issue again this weekend.
from gatsby-plugin-linaria.
Should be working in v1.1.3, please try again.
from gatsby-plugin-linaria.
Same error raises when I run:
gatsby build
That starts to happen after I've updated Gatsby. Same with all versions of your plugin. Develop mode works fine.
from gatsby-plugin-linaria.
Hm, I wasn't able to reproduce the error. Which versions of Gatsby and gatsby-plugin-linaria are you using?
from gatsby-plugin-linaria.
@silvenon I think this is the same issue with #17
from gatsby-plugin-linaria.
@silvenon here is the small repo with two branches https://github.com/guandjoy/gatsby-linaria-test
master - latest versions
prev - versions I used when wrote the comment.
But the result is the same. Now it raises the error in both develop and build cases.
from gatsby-plugin-linaria.
I fixed the TS check and got it to properly configure the loader when typescript was detected, and it still failed.
The only thing that worked was to manually install and add gatsby-plugin-typescript
before gatsby-plugin-linaria
to my config as per the original instructions 🤷
from gatsby-plugin-linaria.
Related Issues (20)
- Make CSS Extraction an option. HOT 1
- Setup renovate
- Setup E2E
- Unexpected token 'export' HOT 12
- Breaks Gatsby v3 HOT 1
- Temporary workaround
- Request to set option `cacheDirectory` HOT 2
- TypeError: filename.endsWith is not a function HOT 2
- npm install issue with Gatsby v4.x.x HOT 2
- Unexpected Runtime errors.
- File with extracted CSS styles not link to my output html
- Support for [email protected]? HOT 1
- Dependency Dashboard
- Plugin doesn't work
- Support Linaria v5 and v6
- Doesn't work with core-js v3 HOT 8
- Option to disable SSR? HOT 4
- Error: Using the "styled" tag in runtime is not supported HOT 3
- Using global styles HOT 5
- Why do we need linaria with gatsbyjs? HOT 10
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from gatsby-plugin-linaria.