@alextheman/utility - v4.3.5
    Preparing search index...

    Variable normalizeIndentsConst

    normalizeIndents: {
        (options: NormaliseIndentsOptions): NormaliseIndentsFunction;
        (strings: TemplateStringsArray, ...interpolations: unknown[]): string;
    } = normaliseIndents

    Applies any options if provided, then removes any extraneous indents from a multi-line template string.

    You can pass a template string directly by doing:

    normalizeIndents`Template string here
    with a new line
    and another new line`.

    You may also pass the options first, then invoke the resulting function with a template string:

    normalizeIndents({ preserveTabs: false })`Template string here
    with a new line
    and another new line`.

    Type Declaration

      • (options: NormaliseIndentsOptions): NormaliseIndentsFunction
      • Provides a new function that removes any extraneous indents from a multi-line template string, with the given options applied.

        Parameters

        Returns NormaliseIndentsFunction

        A function that takes a template string, and returns a new string with the strings and interpolations from the template applied, and extraneous indents removed.

      • (strings: TemplateStringsArray, ...interpolations: unknown[]): string
      • Removes any extraneous indents from a multi-line template string.

        You can pass a template string directly by doing:

        normaliseIndents`Template string here
        with a new line
        and another new line`.

        Parameters

        • strings: TemplateStringsArray

          The strings from the template to process.

        • ...interpolations: unknown[]

          An array of all interpolations from the template.

        Returns string

        A new string with the strings and interpolations from the template applied, and extraneous indents removed.

    The strings from the template to process, or the options to apply.

    An array of all interpolations from the template.

    An additional function to invoke, or a new string with the strings and interpolations from the template applied, and extraneous indents removed.