Sublime-JS-Custom: Typescript / React highlighting broken

Sublime Text 3 JS Custom v3.0.1

JS Custom has just upgraded, and now syntax highlighting in .tsx files (React with TypeScript) is not working correctly.

Example files: JS Custom issues

The screenshot shows two .tsx files. Issues include:

  • class and variable names are not highlighted
  • incorrect hot pink highlighting in both files
  • string quotes not handled correctly

I see this error in the Sublime Text console:

reloading plugin JSCustom.plugin
Traceback (most recent call last):
  File "/opt/sublime_text/sublime_plugin.py", line 125, in reload_plugin
    m = importlib.import_module(modulename)
  File "./python3.3/importlib/__init__.py", line 90, in import_module
  File "<frozen importlib._bootstrap>", line 1584, in _gcd_import
  File "<frozen importlib._bootstrap>", line 1565, in _find_and_load
  File "<frozen importlib._bootstrap>", line 1532, in _find_and_load_unlocked
  File "/opt/sublime_text/sublime_plugin.py", line 1199, in load_module
    exec(compile(source, source_path, 'exec'), mod.__dict__)
  File "/home/user/.config/sublime-text-3/Installed Packages/JSCustom.sublime-package/plugin.py", line 7, in <module>
  File "<frozen importlib._bootstrap>", line 1565, in _find_and_load
  File "<frozen importlib._bootstrap>", line 1532, in _find_and_load_unlocked
  File "/opt/sublime_text/sublime_plugin.py", line 1199, in load_module
    exec(compile(source, source_path, 'exec'), mod.__dict__)
  File "/home/user/.config/sublime-text-3/Installed Packages/JSCustom.sublime-package/src/paths.py", line 7, in <module>
  File "/home/user/.config/sublime-text-3/Packages/sublime_lib/st3/sublime_lib/resource_path.py", line 238, in from_file_path
    "Path {!r} does not correspond to any resource path.".format(file_path)
ValueError: Path PosixPath('/home/user/.config/sublime-text-3/Installed Packages/JSCustom.sublime-package/src/paths.py') does not correspond to any resource path.

About this issue

  • Original URL
  • State: closed
  • Created 3 years ago
  • Comments: 23 (12 by maintainers)

Most upvoted comments

All’s well that ends well? 🤷‍♂️

Yeah, it sounds like your install got into some kind of weird state. I have no idea why uninstalling and reinstalling didn’t fix it the first time.