New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
hovering / color decoration support for custom patterns #247
Comments
You can configure that with custom regex pattern I guess. |
for that
|
well I tried several regexes, including what worked for me with TW, for js/jsreact and couldn't get it to recognize |
If you can show me an example code, I could look into it for you. |
JS like this, React without JSX, also similar to the JS ReScript compiles to: //App.js
const ce = React.createElement;
export default function App() {
return ce(
"div",
{
className: "mt-8",
}
);
} Hovering over the 'mt-8' does nothing unless I replace the ': ' with an equal sign. So in settings I tried: "windicss.includeLanguages": {
"<filetype_identifier>": {
"type":"html",
"patterns": [
"(\\s*class(Name)?\\s*\\:\\s*{?\\s*[\"'`])[^\"'`]*$"
]
}
} with |
@jamessouth, so does autocomplete of classes works? |
Yes, thank you, with this on 21.4 "windicss.includeLanguages": {
"rescript": "html",
"javascript": {
"type":"js",
"patterns": [
"(\\s*class(Name)?\\s*\\:\\s*{?\\s*[\"'`])[^\"'`]*$"
]
}
} the JS hovering and class completion work, but I am not getting color boxes in JS once I select a class from the drop-down menu. I do get color boxes in rescript files though. |
yeah that is something i have to include in a later release |
Ok. Thank you for all your help Alexander! |
Hello, there doesn't seem to be a way to customize class name contexts like in TW. Here is the TW issue. Intellisense works with
className=....
but not withclassName: ....
etc. Could such support be added?Thank you!
The text was updated successfully, but these errors were encountered: