Tweakr
    Preparing search index...

    Function containsIgnoreCase

    • Checks if a string contains a given substring, ignoring case.

      Parameters

      • str: string

        The string to search within.

      • search: string

        The substring to search for.

      Returns boolean

      true if search is found in str (case-insensitive), otherwise false.

      1.1.0

      containsIgnoreCase("Hello World", "hello"); // true
      containsIgnoreCase("Hello World", "WORLD"); // true
      containsIgnoreCase("Hello World", "test"); // false