ixfx
    Preparing search index...

    Function prefixProperties

    • Returns a new object based on data but with all properties prefixed by prefix.

      prefixProperties({ name: `x`, size: 10 }, `test-`);

      // Yields:
      // { test-name: `x`, test-size: 10 }

      Parameters

      • data: Record<string | number, any>[]
      • prefix: string

      Returns Record<string, unknown>[]