Bug Tracker

Opened 6 years ago

Closed 5 years ago

Last modified 5 years ago

#10692 closed enhancement (fixed)

Configure the jshint options to more accurately match the style guide

Reported by: mikesherov Owned by: mikesherov
Priority: low Milestone: 1.7.2
Component: build Version: 1.7
Keywords: Cc:
Blocked by: Blocking:

Description (last modified by mikesherov)

JSHint's configuration options are way better than JSLint's.

In particular, the "undef" option is useful, and would only require minor changes to core code.

1.8?

Change History (18)

comment:1 Changed 6 years ago by Rick Waldron

Component: unfiledmisc
Keywords: 1.8-discuss added
Priority: undecidedlow
Status: newopen

+1 "onevar" changes are DEFINITELY welcome.

comment:2 Changed 6 years ago by dmethvin

Component: miscbuild
Milestone: None1.7.1

Yeah I would love to have a way to catch undeclared variables. Scary.

comment:3 Changed 6 years ago by dmethvin

+1, Yeah!

comment:4 in reply to:  2 Changed 6 years ago by Rick Waldron

Replying to dmethvin:

Yeah I would love to have a way to catch undeclared variables. Scary.

That's another option we can switch on: "undef"

comment:5 Changed 6 years ago by Rick Waldron

@mikesherov - before any code gets written for this... I want to show you a "build tool" system that @cowboy has been developing, it might make easy work of this.

comment:6 Changed 6 years ago by dmethvin

Milestone: 1.7.11.8

comment:7 Changed 6 years ago by timmywil

Summary: use JSHint for the build instead of JSLintConfigure the jshint options to more accurately match the style guide

comment:8 Changed 6 years ago by timmywil

+1, We already use JSHint, but the options need to be configured to match the styleguide. Code should be reorganized so onevar and other available options will pass.

comment:9 Changed 6 years ago by mikesherov

comment:10 Changed 6 years ago by timmywil

You know what, I use jshint locally so often, I couldn't believe we didn't use it. woooops.

comment:11 Changed 6 years ago by timmywil

And I've edited that file several times.

comment:12 Changed 6 years ago by mikesherov

I'll have a PR with just an in place change shortly. After the change is in place, I'll go immediately to work on onevar and undef.

comment:15 Changed 5 years ago by mikesherov

Owner: set to mikesherov
Status: openassigned

comment:16 Changed 5 years ago by mikesherov

Description: modified (diff)

comment:17 Changed 5 years ago by Mike Sherov

Resolution: fixed
Status: assignedclosed

Fix #10692. JSLint is dead! Long live JSHint!

Still needs this sizzle PR: https://github.com/jquery/sizzle/pull/82

Changeset: 98386cfd775fdfa7837ccbec173b04f1e6d57896

comment:18 Changed 5 years ago by dmethvin

Keywords: 1.8-discuss removed
Milestone: 1.81.7.2

There was no reason to wait until 1.8 for this, probably true for any of the build or behind-the-scenes changes if they're easy to do.

Note: See TracTickets for help on using tickets.