Class: JsxRosetta::IR::Prop
- Inherits:
-
Data
- Object
- Data
- JsxRosetta::IR::Prop
- Includes:
- Node
- Defined in:
- lib/jsx_rosetta/ir/types.rb
Overview
A component prop, possibly with a default value.
name : String — the prop name on the parent (e.g. “data-testid”). default : Interpolation | nil alias_name : String | nil — the local binding name inside the body when
the destructure renames it (`"data-testid": dataTestId`).
Use sites of the alias resolve to the prop's ivar.
Instance Attribute Summary collapse
-
#alias_name ⇒ Object
readonly
Returns the value of attribute alias_name.
-
#default ⇒ Object
readonly
Returns the value of attribute default.
-
#name ⇒ Object
readonly
Returns the value of attribute name.
Instance Attribute Details
#alias_name ⇒ Object (readonly)
Returns the value of attribute alias_name
118 119 120 |
# File 'lib/jsx_rosetta/ir/types.rb', line 118 def alias_name @alias_name end |
#default ⇒ Object (readonly)
Returns the value of attribute default
118 119 120 |
# File 'lib/jsx_rosetta/ir/types.rb', line 118 def default @default end |
#name ⇒ Object (readonly)
Returns the value of attribute name
118 119 120 |
# File 'lib/jsx_rosetta/ir/types.rb', line 118 def name @name end |