Skip to content
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

Autocomplete does not work within string templates #2

Open
iangrams opened this issue Feb 8, 2019 · 1 comment
Open

Autocomplete does not work within string templates #2

iangrams opened this issue Feb 8, 2019 · 1 comment

Comments

@iangrams
Copy link

iangrams commented Feb 8, 2019

Firstly, thanks for this plugin, it's immensely helpful!

However, when I'm editing JSX and am within a string template the autocomplete stops working. Seems it only looks for className= with single or double quotes. Would be helpful for React dev if it also worked within string templates.

I believe updating the RegEx on line 149 to something like \bclass(Name)?={*[`"\']([^"\']*)$ should do the trick.

These work:
className='fill-current border-'
className="fill-current border-"

But this does not:
className={`fill-current border-`}

@james2doyle
Copy link

Try my fork: https://github.com/james2doyle/sublime-tailwindcss

I just applied your regex pattern (james2doyle@5243d2c) and tested it out. Seems to work

I have had 3 PRs open since March and they haven't been addressed so maybe give this a shot and see if it fixes your issues

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants