UNPKG

@lobehub/ui

Version:

Lobe UI is an open-source UI component library for building AIGC web apps

15 lines (14 loc) 278 B
//#region src/utils/safeParseJSON.ts const safeParseJSON = (text) => { if (typeof text !== "string") return; let json; try { json = JSON.parse(text); } catch { return; } return json; }; //#endregion export { safeParseJSON }; //# sourceMappingURL=safeParseJSON.mjs.map