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

Allow debugger statements in development JS #1487

Merged
merged 1 commit into from
Jun 21, 2015

Conversation

austinpray
Copy link
Contributor

fixes #1480

cc @aaemnnosttv

@austinpray austinpray added this to the 8.2.3 milestone Jun 4, 2015
@austinpray austinpray force-pushed the gulpDebug branch 2 times, most recently from abeb257 to d84d581 Compare June 4, 2015 15:22
@austinpray
Copy link
Contributor Author

I need some help with the decision to fail the JSHint task.

When JSHint fails:

  • what should happen when in development mode?
  • what should happen when in --production mode?

I was thinking that JSHint should give "by the way" warnings in development but fail production builds. But I'm unsure if this is the way to go. Really would appreciate feedback.

On one hand it makes sure no bad/dangerous code makes it to production. On the other: if you ignore the development JSHint warnings you will be unable to deploy until you pay the JSHint debt.

@Foxaii
Copy link
Contributor

Foxaii commented Jun 5, 2015

The "by the way" warnings are a good idea. One long list of all the changes that need attention is better than just the first fault that has caused the build to fail.

I agree with your thinking that it should be a fail in --production as well. Perhaps document that they need to run in development mode to list the fixes required.

@JulienMelissas
Copy link
Contributor

I agree with @Foxaii - I think it's best if during development it just provides warnings, and during production it should fail. Documentation is a good think to bring up too, thanks for mentioning that!

@austinpray
Copy link
Contributor Author

Perhaps document that they need to run in development mode to list the fixes required.

@Foxaii: in both cases it lists all the errors you need to fix. The only difference is that the production build will fail to compile.

@Foxaii
Copy link
Contributor

Foxaii commented Jun 5, 2015

Nice to know but that doesn't change my agreeing with you, @austinpray.

@austinpray
Copy link
Contributor Author

ping @aaemnnosttv, curious to see what you think about this.

@aaemnnosttv
Copy link
Contributor

@austinpray I think it's a great solution. Great job 👍

austinpray added a commit that referenced this pull request Jun 21, 2015
Allow `debugger` statements in development JS
@austinpray austinpray merged commit a08273e into roots:master Jun 21, 2015
@austinpray austinpray deleted the gulpDebug branch June 21, 2015 03:39
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

Successfully merging this pull request may close these issues.

Problems debugging javascript
4 participants