subtleGradient / language-javascript-jsx

JavaScript with JSX Bundle for Atom
45 stars 6 forks source link

[Enhancement] Add styling for template strings #13

Open elbeezi opened 8 years ago

elbeezi commented 8 years ago

e.g.

const bar = 42;
const baz = `foo ${bar}`; // 'foo 42'

foo should be styled as string and ${bar} should be styled as variable.

http://babeljs.io/docs/learn-es2015/#template-strings

elbeezi commented 8 years ago

P.S. I've never done Atom dev, but if I get a chance I'll dig into the source and see about contributing PR(s).

subtleGradient commented 8 years ago

That should work already

PitmanPete commented 7 years ago

Sorry to dredge up an old report, but template strings are not working for me. With language-javascript-jsx installed if I do a Log Scopes At Cursor (Cmd+Alt+P) I see:

source.js.jsx meta.block.es meta.static meta.function.body variable.other.readwrite.js

If I disable language-javascript-jsx I see: source.js string.quoted.template.js

Running Atom 1.11.2 with language-javascript-jsx 0.3.7

subtleGradient commented 7 years ago

Thanks very much for taking the time to write this up.

Hmm. I could've sworn I had that working already. I do have some local changes that I haven't published, so there's a chance I've fixed this already.

I'm not going to have the time to look into this soon. Your best bet may be too switch to language-babel. I think that one is being better maintained these days.

I'm personally still using TextMate mostly. But I'm also spending a lot of time using IntelliJ these days. I'm hoping to fully switch to Atom eventually. Nuclide adds all kinds of fantastic features.

Sorry for not maintaining this stuff as much as I should. On Thu, Oct 20, 2016 at 7:37 AM PitmanPete notifications@github.com wrote:

Sorry to dredge up an old report, but template strings are not working for me. With language-javascript-jsx installed if I do a Log Scopes At Cursor (Cmd+Alt+P) I see:

source.js.jsx meta.block.es meta.static meta.function.body variable.other.readwrite.js

If I disable language-javascript-jsx I see: source.js string.quoted.template.js

Running Atom 1.11.2 with language-javascript-jsx 0.3.7

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/subtleGradient/language-javascript-jsx/issues/13#issuecomment-255081821, or mute the thread https://github.com/notifications/unsubscribe-auth/AAAQFai7rNkZQmcHGuH1h6CP4NgcNHifks5q11KDgaJpZM4F-enq .

PitmanPete commented 7 years ago

np, thanks for replying so quick. language-babel looks like a good shout - thanks again!