Martin

Results 110 comments of Martin

Is it possible to push the css as string instead of a file path?

Sorry, the extractFile function receive the css as string and should make the group handling too. https://github.com/windicss/vite-plugin-windicss/blob/ce166a0334f1a36e9d24513caf391a53585ac249/packages/plugin-utils/src/createUtils.ts#L161 But it does not work in my case.

🤦 Embarrassing, now I understand it too. The detection works. ![image](https://user-images.githubusercontent.com/6279703/114272909-46a45700-9a18-11eb-82d7-0149566ce69b.png) 🤔 ... I will think about it.

Hello @antfu, I implemented a tiny devtool script that transforms the class declaration like Windi under the hood. But today I have no idea how to dynamically insert it into...

I could try to inject the devtool snippet only in `development` mode.

Update prototype - valid W3C - https://developer.mozilla.org/en-US/docs/Web/API/MutationObserver ```ts const regexClassGroup = /([!\w+-][\w+:_/-]*?\w):\(([\w\s/-]*?)\)/gm; function transformGroups(str: string) { return str.replace(regexClassGroup, (_, a: string, b: string) => b .split(/\s/g) .map((i) => `${a}:${i}`) .join('...

Hi @antfu, unfortunately not if you use a precompiler like SASS, LESS etc. ![image](https://user-images.githubusercontent.com/6279703/117558485-2ea70e00-b07e-11eb-8bb9-cbb7cc5551eb.png)

This hack works ... Focus: https://github.com/gotwarlost/istanbul/pull/603 # Proof-of-Concept: ## .babel.rc ```bash { "plugins": [ "transform-class-properties", "transform-flow-strip-types", "discard-module-references" ], "presets": [ "es2015" ] } ``` ## Move all class property initializations...

**I think we should handle invalid pathes.** You can reproduce it like that: ``` mkdir reproduce cd reproduce npm i @leanup/cli@next @leanup/cli-react@next npx react create npm run build ``` ![image](https://user-images.githubusercontent.com/6279703/112941329-b10eea80-912e-11eb-912e-004c0b7409b2.png)

There is a `stencil` issue in the update: https://github.com/ionic-team/stencil/issues/5766