Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
sublime jslint settings
// an array of options to pass to jslint.
"options" : [
// examples using predef flag.
"--predef", "['angular', 'document', '\\$', '_', 'jQuery', 'FB', 'window', 'Bootstrapper']"
// tolerate missing 'use strict' pragma.
// suggest an indent level of two spaces.
,"--indent", "4"
// assume node.js to predefine node globals.
// tolerate unfiltered for in.
// tolerate dangling _ in identifiers.
// tolerate many var statements per function.
// tolerate ++ and --.
// tolerate blocking -Sync methods
// tolerate comments starting with TODO
// if true, run jslint on save.
,"run_on_save" : true
// a regex string to determine whether jslint
// should be run on a file.
// if a match is found (i.e., filename)),
// the file will be linted.
,"filename_filter": "(\\.js|\\.json|\\.gs)$"
// jslint command you want to run as an array of strings.
// E.g.: ["jslint"] or ["/usr/local/bin/jslint"] or ["node", "mylinter.js"]
// Default is
// * Linux: ["node", "~/.config/sublime-text-2/Packages/JSLint/linter.js"]
// * Mac: ["node", "~/Library/Application Support/Sublime Text 2/Packages/JSLint/linter.js"]
// * Windows: ["node", "%APPDATA%/Sublime Text 2/Packages/JSLint/linter.js"]
// ,"jslint" : ["jslint"]
// if your own personal choice of jslint has an output
// different from the standard which comes with this package,
// you may have to change line_regex and file_regex
// check
// to find out how these regular expressions work. The defaults are:
// ,"line_regex" : ".*// Line ([0-9]*), Pos ([0-9]*)$"
// ,"file_regex" : "(^[^# ]+.*$)"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.