Leverage json-with-bigint's typings
All checks were successful
Build / build (20) (push) Successful in 1m5s
Build / build (18) (pull_request) Successful in 43s
Build / build (20) (pull_request) Successful in 1m4s
Build / build (22) (pull_request) Successful in 1m6s
Build / build (22) (push) Successful in 40s
Build / build (18) (push) Successful in 1m9s

This commit is contained in:
Sainan 2025-03-19 10:31:58 +01:00
parent 9667b6f72c
commit 4ed0851501

View File

@ -2,7 +2,7 @@ import { JSONParse } from "json-with-bigint";
export const getJSONfromString = <T>(str: string): T => {
const jsonSubstring = str.substring(0, str.lastIndexOf("}") + 1);
return JSONParse(jsonSubstring) as T;
return JSONParse<T>(jsonSubstring);
};
export const getSubstringFromKeyword = (str: string, keyword: string): string => {