struct

Ktistec::SafeJSON

Inherits Struct < Value < Object

A String wrapper marking JSON output safe to emit raw into the body of an inert <script type="application/json"> block.

Constructors

assert_safe(json : String) : SafeJSON

Asserts the input is already safe JSON.

Source
from(value) : SafeJSON

Serializes value as JSON.

Source

Instance methods

==(other : SafeJSON) : Bool
Source
==(other : String) : Bool
Source
empty?(*args, **options)
Source
empty?(*args, **options, &)
Source
size(*args, **options)
Source
size(*args, **options, &)
Source
to_s(*args, **options)
Source
to_s(*args, **options, &)
Source