How to use the json-stable-stringify.default function in json-stable-stringify

To help you get started, we’ve selected a few json-stable-stringify examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github JohnSimerlink / branches_front_end_private / app / objects / tree / TreeUtils.ts View on Github external
export function createTreeId({contentId, parentId}: { contentId: id, parentId: id }): id {
	const objectToStringify = {
		contentId,
		parentId
	};
	const stringified = stringify(objectToStringify);
	const treeId = md5(stringified);
	return treeId;
}

json-stable-stringify

deterministic JSON.stringify() with custom sorting to get deterministic hashes from stringified results

MIT
Latest version published 3 months ago

Package Health Score

79 / 100
Full package analysis

Popular json-stable-stringify functions