Comments (6)
Yeah, I've known about this but I don't think there's a solution. Sublime can't match across new lines, but a single JSX tag can run multiple lines - in fact, it's a very common pattern:
<div className='PanelSearch'>
Search<input
className='PanelSearch-field'
/* comments */
onChange={this.onInputChangeHandler}
onKeyDown={this.onInputKeyDownHandler}
value={props.query}
/>
</div>
So we only match the opening part of the tag (e.g.: <Tag
) then try to match attributes and comments, since those can be on another line.
from babel-sublime.
Are semicolons allowed inside JSX tags? If not, maybe that can be a heuristic to differentiate JSX tags from comparison operator.
from babel-sublime.
@dashed good call! Can you and @hawkrives give #33 a test drive before I merge it?
from babel-sublime.
@hawkrives I just pushed the fix for this issue in v2.0.0 - should be picked up by Package Control within the hour.
from babel-sublime.
Excellent. Sorry I didn't get around to testing this— today was a bit hectic.
I'll see if I spot anything!
On Sat, Feb 14, 2015 at 10:28 PM, Andres Suarez [email protected]
wrote:
@hawkrives I just pushed the fix for this issue in v2.0.0 - should be picked up by Package Control within the hour.
Reply to this email directly or view it on GitHub:
#29 (comment)
from babel-sublime.
no worries!
from babel-sublime.
Related Issues (20)
- Babel issue HOT 1
- Inline comments breaking if comment begins with @ symbol HOT 5
- Version 11 broke syntax highlighting. HOT 15
- Object keys highlighting slightly incorrect in recent release HOT 5
- Question on how to short-circuit on ``` for fenced code blocks in Markdown HOT 5
- Sublime 4 Crashing HOT 4
- Possible highlighting error using a nested ternary HOT 3
- Highlighting error not using parentheses inside an if condition HOT 7
- Error loading syntax file: 'Packages/Babel/JavaScript (Babel).sublime-syntax' HOT 18
- ST4 Autocomplete does not consider state variables defined in a map HOT 1
- Missing Babel option in syntax selector. HOT 2
- Highlighting of `filter` in `styled-components` seems to break— HOT 3
- css Styled Component helper utility improperly highlighted HOT 3
- Functions with parameters on multiple lines are not highlighted properly. HOT 1
- JS #myPrivateClassMethod() breaks syntax highlighting HOT 6
- Object keys are now red instead of intended yellow on Monokai HOT 2
- Sublime 4149 generates "Error loading syntax file[...]: no such target" pop-up for "JavaScript (Babel)" HOT 3
- Interface in extends class is not well Colored HOT 4
- Object literal property has incorrect color in Sublime 4169
- support html`<b>babel</b>` html syntax in templates HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from babel-sublime.