NOTE: This gem has been deprecated and is superceded by the guard-jshintrb gem
Guard plugin to verify that Javascript files comply with JSLint validations.
Install and configure the JSLint on Rails gem.
Install the gem:
$ gem install guard-jslint-on-rails
Add it to your Gemfile (inside development group):
gem 'guard-jslint-on-rails'
Add guard definition to your Guardfile by running this command:
$ guard init jslint-on-rails
# Guardfile
guard 'jslint-on-rails' do
# watch for changes to application javascript files
watch(%r{^app/assets/javascripts/.*\.js$})
# watch for changes to the JSLint configuration
watch('config/jslint.yml')
end
# Guardfile
guard 'jslint-on-rails', :config => '/path/to/jslint.yml' do
end
:config - path to jslint.yml config file. default is config/jslint.yml
Please read Guard doc for more information about the Guardfile DSL.
This library is released under the MIT license: