Microgem: JSLintRB-v8

by on

GOAL: Provide a Ruby interface for running JSLint on javascript files using v8.
require 'jslintrb-v8'
puts JSLint.new.check("var x = 5")
Will return the string:
Error at line 1 character 1: Missing "use strict" statement.
var x = 5
Error at line 1 character 10: Missing semicolon.
var x = 5
Also, all of jslint's configuration options are available in the constructor:
JSLint.new(:undef => false, :sub => true)
JSLintRB-v8 on Github
JSLintRB-v8 on Rdoc.info
blog comments powered by Disqus