Support Linaria v5 and v6
When can we expect support?
Linaria v6 has a major change in the package structure. It requires different work than Linaria v5, but I'm not sure if I can skip it.
@Karol-Waliszewski What version are you using?
@cometkim – What are the requirements for getting this plugin to work for Linaria v5 / v6? I'd love to help out, but am not super familiar with Gatsby's plugin architecture.
@prayash Nothing specific yet. I just don't use Linaria recently.
Maybe I can make this plugin work with v5 or v6+, but not both. They have very different configurations, and I don't have enough energy to maintain multiple variants.
What version of Linaria do you need?
@cometkim – No problem at all. I was just wondering if there's a good way to help out. Is it as simple as cloning the repo, changing the Webpack configuration in https://github.com/cometkim/gatsby-plugin-linaria/blob/main/src/gatsby-node.ts#L25-L51, and testing locally with newer versions of Linaria on a Gatsby starter project?
I do see some guidance on Linaria's repo around Webpack configs here and also a v6 migration guide. FWIW, I don't think it's worth spending time migrating this plugin to support Linaria v5 since it seems the path from v3/4/5 → 6 is the same.
I'm on the following setup and things are working fine for me, but it would be amazing to eventually support linaria v6! If not, is there another zero runtime CSS-in-JS solution you're using that works well with Gatsby?
@linaria/core": "^4.2.0",
"@linaria/react": "^4.2.0",
"@mdx-js/react": "^3.0.0",
"gatsby": "^5.14.1",
Well the basic setup should be pretty simple, but afaik starting from v6 it uses wyw-in-js toolchain, so we need to make sure that it is compatible with existing features of this plugin like critical css extraction.
Maybe I can do #107 first, to make easier to validate it