Function getSafeJson

  • Validate and return sanitized JSON.

    Note: This function uses sanitized JsonStruct for validation that applies stringify and then parse of a value provided to ensure that there are no getters which can have side effects that can cause security issues.

    Returns

    Sanitized JSON structure.

    Type Parameters

    Parameters

    • value: unknown

      JSON structure to be processed.

    Returns Type