Class: JsxRosetta::IR::Comment

Inherits:
Data
  • Object
show all
Includes:
Node
Defined in:
lib/jsx_rosetta/ir/types.rb

Overview

A comment lifted from JSX (‘… */`). Backends decide how to surface it (ERB `<%# … %>`, HTML `<!– –>`, etc.).

text : String — comment body verbatim, including any leading/trailing

whitespace from the JSX source.

Instance Attribute Summary collapse

Instance Attribute Details

#textObject (readonly)

Returns the value of attribute text

Returns:

  • (Object)

    the current value of text



175
176
177
# File 'lib/jsx_rosetta/ir/types.rb', line 175

def text
  @text
end