• Returns whether the given text includes the comparison string

    Parameters

    • Optionaltext: null | string

      the source string to check

    • Optionalcomparison: null | string

      the target string to compare

    Returns boolean

    whether the given text includes the comparison string

    includes('foobar', 'foo');    // true