Embedded v8 in C which links to ruby, so you can validate JS code while in Ruby
C C++ Other
Switch branches/tags
Nothing to show
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
V8
README
test.rb
this_fails.js
this_works.js
this_works_too.js

README

This embeds V8 in a module, so you can validate javascript files in Ruby.

Basic Example:

require 'V8/V8'

puts V8.compile('some_javascript.js')


This will return either false (for no errors) or an array of errors.
Demo usage is in test.rb

You may have to compile V8 yourself and replace the libv8.a file.