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

Fix/js vue html issues + feat #92

Merged
merged 4 commits into from Sep 25, 2023
Merged

Fix/js vue html issues + feat #92

merged 4 commits into from Sep 25, 2023

Conversation

roosta
Copy link
Member

@roosta roosta commented Jul 11, 2023

Fix/js vue html issues + feat

  • I linked the hl group javaScript to normal. This makes inline <script> blocks in html much nicer, and fixes javavscript highlighting in vim-vue plugin.

  • I've also sorted and and cleaned up the javascript syntax file

  • there is one feat commit here, despite the branch name, it clears some syntax hl groups for javascript, so that it'll fall back to what is defined top level (symbol, statement etc(colors/srcery.vim)) This adds some needed variety to js colors, and brings it more inline with other languages.

Keeping this as a draft for now, because I can't understand why the html plugin would set javaScript to Special. I first thought it had something to do with a couple of syntax plugins I used but digging through nvim runtime folders it seems the hlgroup is defined in html syntax file. I've looked at other colorschemes to see if they even set javaScript to anything at all and I can't find any, which makes me think its something I'm missing here.

@roosta roosta force-pushed the fix/js-vue-html-issues branch 2 times, most recently from 5c52e23 to a9f78c6 Compare August 24, 2023 08:14
This way javascript in embedded script tags will look fairly normal,
some differences cant be accounted for, but close enough.

Previously it would render all normal javascript text as special (see
html.vim, in my case /usr/share/nvim/runtime/html.vim)
JavaScript being builtin
- identifier
- function
- operator

Fall back to vim defaults for these, brings javascript more in line with
other languages. It was also very heavy on the red, so it gets a bit
more balanced out
Its the html plugin that defines it, so this is a more correct
placement. I considered a rebase, but got to messy, this commit leaves a
clean history
@roosta roosta marked this pull request as ready for review September 25, 2023 12:30
@roosta roosta merged commit 8ea4c4f into master Sep 25, 2023
1 check passed
@roosta roosta deleted the fix/js-vue-html-issues branch September 25, 2023 12:32
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

Successfully merging this pull request may close these issues.

None yet

1 participant