refactor: use Options instead of Errors

This commit is contained in:
rusconn
2023-06-01 13:40:06 +09:00
parent 2b6d346b74
commit d935d0579f
8 changed files with 51 additions and 55 deletions

3
lib/json.ts Normal file
View File

@@ -0,0 +1,3 @@
import { tryCatchK } from "fp-ts/lib/Option";
export const safeJsonParse = tryCatchK(JSON.parse);