This repository was archived by the owner on Dec 15, 2022. It is now read-only.
Prevent autoindenting when a brace appears inside a regex#583
Open
lnestor wants to merge 1 commit intoatom:masterfrom
lnestor:master
Open
Prevent autoindenting when a brace appears inside a regex#583lnestor wants to merge 1 commit intoatom:masterfrom lnestor:master
lnestor wants to merge 1 commit intoatom:masterfrom
lnestor:master
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description of the Change
Currently, the line following a brace inside a regex is automatically indented.


This change makes it so the next line is not indented.
Alternate Designs
The other alternative would be to let the next line be indented if this is the desired functionality. This could be adjusted as a setting, but I don't think it is important enough to warrant its own setting.
Benefits
Aesthetics changes when writing regexes.
Possible Drawbacks
If you put a closing brace on the next line as the first character, it will outdent past the regex.


The normal behavior currently looks like the following.
Applicable Issues
This was referenced in issue atom/atom#17571.