@selenite/graph-editor
Version:
A graph editor for visual programming, based on rete and svelte.
17 lines (16 loc) • 475 B
JavaScript
// export * from './uuid';
// export * from './context';
export { formatXml } from './xml';
export * from './url';
export * from './string';
export * as DaisyUI from './daisyui';
export * from './daisyui';
import { v4 as uuidv4 } from 'uuid';
let idCount = 0;
export function newLocalId(baseName) {
idCount += 1;
return `${baseName ?? 'local-unique-id'}-${idCount}}`;
}
export function newUuid(baseName) {
return `${baseName ? baseName + '-' : ''}${uuidv4()}`;
}