Pebble App Framework: Phone API
    Preparing search index...

    Function safeParse

    • Parses a JSON string, returning null on failure. The result is the raw unknown JSON, so a provider casts it to its own response shape.

      Parameters

      • body: string

        The raw response body to parse.

      Returns unknown

      The parsed JSON, or null when the body is not valid JSON.