Skip to content

Commit d898789

Browse files
authored
docs: tailwind classes intelliSense autocompletion in vscode for styled util functions (#873)
1 parent 42f2bf2 commit d898789

File tree

1 file changed

+19
-0
lines changed
  • apps/website/src/routes/docs/styled/(getting-started)/install

1 file changed

+19
-0
lines changed

apps/website/src/routes/docs/styled/(getting-started)/install/index.mdx

+19
Original file line numberDiff line numberDiff line change
@@ -259,3 +259,22 @@ export * from './select/select';
259259
This way you can now `import { Accordion, Alert, ... } from '~/components/ui';` 👯‍♀️
260260

261261
(**small tip:** you can commment out the components you don't use!)
262+
263+
## Tailwind CSS IntelliSense VSCode extension
264+
265+
If you don't already have it, go ahead and install the [Tailwind CSS IntelliSense](https://marketplace.visualstudio.com/items?itemName=bradlc.vscode-tailwindcss) extension for vscode.
266+
267+
Then, edit your [settings.json](https://code.visualstudio.com/docs/getstarted/settings) with the following:
268+
269+
```json
270+
{
271+
"tailwindCSS.experimental.classRegex": [
272+
["cva\\(([^)]*)\\)", "[\"'`]([^\"'`]*).*?[\"'`]"],
273+
["cn\\(([^)]*)\\)", "(?:'|\"|`)([^']*)(?:'|\"|`)"]
274+
]
275+
}
276+
```
277+
278+
This will enable the extension to recognize the Qwik UI utility functions and give you the same autocompletion you get with the default Tailwind classes.
279+
280+
You can thank us later... 😉

0 commit comments

Comments
 (0)