UNPKG

@expofp/floorplan

Version:

Interactive floor plan library for expos and events

2 lines (1 loc) • 276 B
import l from"slugify";import{eventScopedValue as s}from"./event-scoped-cache.js";const u=s(()=>new Set);export function generateUniqueSlug(r){const t=u();let o=0;const n=l(r,{remove:/[*+~.()'"!:@]/g,lower:!0});let e;do e=n+(o++>0||!n?o:"");while(t.has(e));return t.add(e),e}