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

Sublime Babel #1

Closed
mattmacpherson opened this issue Jun 13, 2017 · 10 comments
Closed

Sublime Babel #1

mattmacpherson opened this issue Jun 13, 2017 · 10 comments

Comments

@mattmacpherson
Copy link

What's the difference between this and Sublime Babel?

@michaelgmcd
Copy link
Owner

In regular JavaScript, there are only subtle differences (import/export statements and function calls), however the real difference is that this package has improved Flow support as well as syntax highlighting for GraphQL and styled-components. While Sublime Babel supports React and JSX pretty well, I personally prefer the highlighting provided by this package (mainly that JSX components are treated the same as classes).

It's all obviously a matter of preference and this is mine!

Sublime Babel:
screen shot 2017-06-12 at 10 14 02 pm

Babel JavaScript:
screen shot 2017-06-12 at 10 17 15 pm

Sublime Babel:
screen shot 2017-06-12 at 10 10 51 pm
Babel JavaScript:
screen shot 2017-06-12 at 10 10 15 pm

Sublime Babel:
screen shot 2017-06-12 at 10 11 40 pm
screen shot 2017-06-12 at 10 13 23 pm
Babel JavaScript:
screen shot 2017-06-12 at 10 09 37 pm

Sublime Babel:
screen shot 2017-06-12 at 10 16 07 pm
Babel JavaScript:
screen shot 2017-06-12 at 10 08 55 pm

@mattmacpherson
Copy link
Author

@mgmcdermott Thanks for the detailed response. I respect your attention to detail and I'm definitely giving it a try!

@xDae
Copy link

xDae commented Jun 14, 2017

also comment that in this package commenting inside JSX works better than in sublime babel

Sublime babel comments JSX with // xxx
this package comments JSX in the correct way with {/* xxx */}

@kurtextrem
Copy link

kurtextrem commented Jun 16, 2017

Regarding the screenshots:
The import screenshots seem switched - the first screenshot shows Babel JavaScript, the second Sublime Babel (using "Material Theme").

Regarding the JSX Tags:
I can't see why the Babel JavaScript color should be correct. Open an HTML file, write a few tags. They're not yellow, they're red. Hence, the JSX tags should be red as well (like Sublime Babel).

@michaelgmcd
Copy link
Owner

All screenshots were taken using the "Theme - Oceanic Next" theme.

@michaelgmcd
Copy link
Owner

michaelgmcd commented Jun 16, 2017

Regarding your second point, valid html tags (input, p, span, h1, etc) will be red just like html. Components (with a capital letter) are NOT valid html and hence they are colored like the classes that they are.

I wanted to show the differences in this issue. Both Sublime Babel and Babel JavaScript will highlight default html tags as red.

@kurtextrem
Copy link

I see, that makes sense. Had not noticed that (subtle but important) difference :)

@rattrayalex-stripe
Copy link

Sorry, can you provide screenshots for any differences in flow-types as well?

@hamzashahab1610
Copy link

can you please tell me what font is this??

@xxczaki
Copy link

xxczaki commented Jan 7, 2020

@hamzashahab1610 It is Operator Mono

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

No branches or pull requests

7 participants