c

jshelpers

OptionOps

final class OptionOps[T] extends AnyVal

If you want js.UndefOr, use JSConverters .toOptionand .orUndefined.

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

Instance Constructors

  1. new OptionOps(a: Option[T])

Value Members

  1. final def !=(arg0: Any): Boolean
    Definition Classes
    Any
  2. final def ##: Int
    Definition Classes
    Any
  3. final def ==(arg0: Any): Boolean
    Definition Classes
    Any
  4. def ??[B >: T](default: => B): B
  5. def ???[B >: T](other: Option[B]): Option[B]
  6. final def asInstanceOf[T0]: T0
    Definition Classes
    Any
  7. def filterNull: Option[T]

    Filter nulls out in case it *might* be null.

  8. def filterTruthy: Option[T]

    If Some and value is truthy according to JS, then keep it, otherwise become a None.

  9. def getClass(): Class[_ <: AnyVal]
    Definition Classes
    AnyVal → Any
  10. final def isInstanceOf[T0]: Boolean
    Definition Classes
    Any
  11. def orElseNull: Option[T]

    If Some, keep the value, else set the value to null.

  12. def toString(): String
    Definition Classes
    Any

Deprecated Value Members

  1. def toNonNullOption: Option[T]

    Filter nulls out in case it *might* be null.

    Filter nulls out in case it *might* be null.

    Deprecated

    USe filterNull.

Inherited from AnyVal

Inherited from Any

Ungrouped