christianalfoni / webpack-bin

A webpack code sandbox
http://www.webpackbin.com
MIT License
710 stars 75 forks source link

Template literals highlighting #238

Closed mariuslundgard closed 7 years ago

mariuslundgard commented 7 years ago

The syntax highlighter is not working correctly for template literals (ES2015):

image

PS. Great tool!

christianalfoni commented 7 years ago

Not supported in CodeMirror: https://github.com/codemirror/CodeMirror/issues/3026 :-(

But added string color to template literals at least (in next deploy)

mariuslundgard commented 7 years ago

https://github.com/atom/highlights

christianalfoni commented 7 years ago

Yeah, this will not work @mariuslundgard, cause it is codemirror that creates all the HTML. It needs to know everything that is going on to understand what line your are on, character etc. So codemirror has its own parsers. Sorry :(

mariuslundgard commented 7 years ago

Ah, makes sense, CodeMirror is not simply syntax highlighting, but a code editor 👍