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

Support setting none in REACT_EDITOR env variable #3721

Merged
merged 4 commits into from
Jan 9, 2018

Conversation

raerpo
Copy link
Contributor

@raerpo raerpo commented Jan 9, 2018

This aims to solve #3706

I updated the README to indicate that you can set REACT_EDITOR to none in order to avoid opening the text editor automatically.

@facebook-github-bot
Copy link

Thank you for your pull request and welcome to our community. We require contributors to sign our Contributor License Agreement, and we don't seem to have you on file. In order for us to review and merge your code, please sign up at https://code.facebook.com/cla. If you are contributing on behalf of someone else (eg your employer), the individual CLA may not be sufficient and your employer may need the corporate CLA signed.

If you have received this in error or have any questions, please contact us at cla@fb.com. Thanks!

@@ -257,6 +257,11 @@ function launchEditor(fileName, lineNumber) {
}

let [editor, ...args] = guessEditor();

if (editor.toLowerCase() === 'none') {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This could be null.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it's ok if i just modify the condition? editor && editor.toLowerCase() === 'none'

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We could just move this condition after the next one.

@facebook-github-bot
Copy link

Thank you for signing our Contributor License Agreement. We can now accept your code for this (and any) Facebook open source project. Thanks!

@gaearon
Copy link
Contributor

gaearon commented Jan 9, 2018

Instead of an extra check let's just move the condition down?

@raerpo
Copy link
Contributor Author

raerpo commented Jan 9, 2018

Done! thanks for your help

@gaearon gaearon added this to the 1.0.18 milestone Jan 9, 2018
@gaearon gaearon merged commit e3e8cdd into facebook:master Jan 9, 2018
Pavek pushed a commit to Pavek/create-react-app that referenced this pull request Jul 10, 2018
* add support to set REACT_EDITOR to none

* change README message

* change condition to avoid problems with editor being null

* move condition to avoid extra code
zmitry pushed a commit to zmitry/create-react-app that referenced this pull request Aug 14, 2018
* add support to set REACT_EDITOR to none

* change README message

* change condition to avoid problems with editor being null

* move condition to avoid extra code
@lock lock bot locked and limited conversation to collaborators Jan 20, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants