wildstar
    Preparing search index...
    • Matches a path against a pattern and replaces using the replacement path if matched (case-insensitive)

      Parameters

      • source: string

        The input path to match

      • pattern: string

        The pattern path, may contain *, *+, **, **+ wildcards

      • replacement: string

        The replacement path, may contain <1>, <2>, ... for captures

      Returns null | string

      The replaced path if matched, or null if not matched

      remap('foo/bar/baz', 'FOO/**+/BAZ', 'new/<1>') // returns 'new/bar'