Closed sndrs closed 5 years ago
Hey Alex, I couldn't reproduce this issue. Can you just use this:
"html-css-class-completion.includeGlobPattern": "**/*.{css,scss,sass,slim,latte,html,twig,php,erb}",
With above config, is it working?
Above sample used this config:
"html-css-class-completion.includeGlobPattern": "dist/bootstrap.min.css",
Could you send me the erb
, css
and settings.json
file?
If you want send them to gencer@nienbo.co.uk
so they stay hidden here.
BTW, which extension do you use for highlighting erb
files?
hi gencer, thanks for having a look!
I've just done as you did, put together a very simple project with one erb
file and the exact same css file I'm hoping to load:
{
"html-css-class-completion.includeGlobPattern": "dist/styles.css"
}
everything worked as you'd expect.
however, comparing the output in dev tools, the simple project reported:
[Extension Host]% 1 parseable documents found
console.ts:134 [Extension Host]% 1846 CSS class definitions found
console.ts:134 [Extension Host]% 857 unique CSS class definitions found
console.ts:134 [Extension Host]% 0 failed attempts to parse. List of the documents:
while the original one that's not working reports
[Extension Host]% 1 parseable documents found
console.ts:134 [Extension Host]% 35087 CSS class definitions found
console.ts:134 [Extension Host]% 6853 unique CSS class definitions found
console.ts:134 [Extension Host]% 0 failed attempts to parse. List of the documents:
they're both only trying to index one file, and the file is the same both times. will see if I can get to the bottom of why...
BTW, which extension do you use for highlighting erb files?
just the rebornix.ruby
one :) theme is monokai pro
This is weird. It should result the same numbers on both cases if the files are exact same. I will investigate this difference on my end.
BTW, When you use default settings
on your existing project (not the test one), does it work? Or, Only works on empty project just like above?
just the rebornix.ruby one :) theme is monokai pro
Ok. I was suspected on something else. We can eliminate this.
default settings made no difference unfortunately. i think I first focused the globbing on to that single file because it's a big project, a lot of sass partials around and a lot of css files in dist I don't need to know about. I wonder if that makes a difference? feels as though the glob is returning extra things maybe?
it wouldn't explain what the weird thing about the main project is though... is there a way to enable more thorough debugging by any chance?
Sorry for late reply. I had a surgery. Anyway, do you see the file (css one) after this console log-line:
I will try to add more verbose logging to the extension.
hi @gencer – sorry for not getting back to you, but I've just noticed it's started working as expected! I've no idea what's changed, but it has :)
hi @sndrs, I am very happy to hear that! Let me know if you encounter any other issues.
I have a workspace setting for
"html-css-class-completion.includeGlobPattern": "dist/framework.css"
. that file definitely exists, and the extension seems happy it's indexed everythingbut no classes ever come up in
html.erb
files...I'm sure I'm doing something stupid but I can't think what! any ideas? would you expect this to work?