Class: JsxRosetta::IR::RouteEntry

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

Overview

A single React Router route entry.

path : String — the JSX path attribute verbatim (e.g. “/posts/:id”). element_name : String — the JSX element name from element=/>

(e.g. "PostShow"). Member-expression forms ("Layout.Index")
are flattened to the rightmost name.

Instance Attribute Summary collapse

Instance Attribute Details

#element_nameObject (readonly)

Returns the value of attribute element_name

Returns:

  • (Object)

    the current value of element_name



245
246
247
# File 'lib/jsx_rosetta/ir/types.rb', line 245

def element_name
  @element_name
end

#pathObject (readonly)

Returns the value of attribute path

Returns:

  • (Object)

    the current value of path



245
246
247
# File 'lib/jsx_rosetta/ir/types.rb', line 245

def path
  @path
end