Merge branch 'master' of https://github.com/Azgaar/Fantasy-Map-Generator into burg-groups

This commit is contained in:
Azgaar 2024-12-12 13:29:40 +01:00
commit e402120b8d
42 changed files with 1526 additions and 1067 deletions

View file

@ -57,6 +57,14 @@ JSON.isValid = str => {
}
};
JSON.safeParse = str => {
try {
return JSON.parse(str);
} catch (e) {
return null;
}
};
function sanitizeId(string) {
if (!string) throw new Error("No string provided");