module Rollbar

The Rollbar module. It stores a Rollbar::Notifier per thread and provides some module methods in order to use the current thread notifier.

Allows a Ruby String to be used to pass native Javascript objects/functions when calling JSON#generate with a Rollbar::JSON::JsOptionsState instance.

Example: JSON.generate(

{ foo: Rollbar::JSON::Value.new('function(){ alert("bar") }') },
Rollbar::JSON::JsOptionsState.new

)

> ‘{“foo”:function(){ alert("bar") }}’

MUST use the Ruby JSON encoder, as in the example. The ActiveSupport encoder, which is installed with Rails, is invoked when calling Hash#to_json and as_json, and will not work.