MCPcopy Create free account
hub / github.com/code100x/cms / validateJSON

Function validateJSON

src/components/admin/AddContent.tsx:64–71  ·  view source on GitHub ↗
(value: string)

Source from the content-addressed store, hash-verified

62 };
63
64 const validateJSON = (value: string) => {
65 try {
66 JSON.parse(value);
67 return true;
68 } catch (error) {
69 return false;
70 }
71 };
72
73 const handleContentSubmit = async () => {
74 setLoading(true);

Callers 1

handleContentSubmitFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected