object Route

Route, most commonly used router component. Watch out for which apply method you use as rendering with path, children or exact=true does different thnigs. Rendering with a "component" specified as the prop is not supported. Rendering with children means that the child is always rendered regardless of whether there is a match or not.

Type parameter S stands for "state" which is state you can add to the history stack per push. P is a js object for query parameters, hence, each property should have a string value. Using the children props always renders regardless of path match. Typically, use the render prop.

Linear Supertypes
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. Route
  2. AnyRef
  3. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. Protected

Type Members

  1. trait Props[S, P] extends Object with RouteProps[S]
    Annotations
    @JSType()

Value Members

  1. final def !=(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  2. final def ##: Int
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  4. def always[S, P](children: Function1[RouteComponentProps[S, P], ReactNode]): ReactElement
  5. def always(children: ReactNode): ReactElement
  6. def apply[S, P](props: Props[S, P])(children: Function1[RouteComponentProps[S, P], ReactNode]): ReactElement

    Uses children prop.

  7. def apply[S, P](props: Props[S, P], child: ReactNode): ReactElement
  8. final def asInstanceOf[T0]: T0
    Definition Classes
    Any
  9. def clone(): AnyRef
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.CloneNotSupportedException]) @native() @HotSpotIntrinsicCandidate()
  10. final def eq(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  11. def equals(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef → Any
  12. final def getClass(): Class[_ <: AnyRef]
    Definition Classes
    AnyRef → Any
    Annotations
    @native() @HotSpotIntrinsicCandidate()
  13. def hashCode(): Int
    Definition Classes
    AnyRef → Any
    Annotations
    @native() @HotSpotIntrinsicCandidate()
  14. final def isInstanceOf[T0]: Boolean
    Definition Classes
    Any
  15. final def ne(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  16. final def notify(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native() @HotSpotIntrinsicCandidate()
  17. final def notifyAll(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native() @HotSpotIntrinsicCandidate()
  18. final def synchronized[T0](arg0: => T0): T0
    Definition Classes
    AnyRef
  19. def toString(): String
    Definition Classes
    AnyRef → Any
  20. final def wait(arg0: Long, arg1: Int): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])
  21. final def wait(arg0: Long): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException]) @native()
  22. final def wait(): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])
  23. def withExactPath(p: |[String, Array[String]], child: ReactNode): ReactElement

    With exact = true

  24. def withExactPathRender[S, P](p: |[String, Array[String]])(thunk: Function1[RouteComponentProps[S, P], ReactNode]): ReactElement

    Uses render prop.

  25. def withPath[S, P](p: |[String, Array[String]])(children: Function1[RouteComponentProps[S, P], ReactNode]): ReactElement

    Uses children prop.

  26. def withPath(p: |[String, Array[String]], child: ReactNode): ReactElement
  27. def withPathRender[S, P](p: |[String, Array[String]])(thunk: Function1[RouteComponentProps[S, P], ReactNode]): ReactElement

    Uses render prop.

  28. object JS extends Object with ReactJSComponent
    Annotations
    @native() @JSImport("react-router-dom", "Route")

Deprecated Value Members

  1. def finalize(): Unit
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.Throwable]) @Deprecated @deprecated
    Deprecated

    (Since version ) see corresponding Javadoc for more information.

Inherited from AnyRef

Inherited from Any

Ungrouped