export function isMatchPath()

in packages/ide-toolbox/src/routing/routing.ts [35:45]


export function isMatchPath(path: string, exact: boolean = false): boolean {
  const currentPath = getCurrentPath();
  const match = new RegExp(transformPath(path)).exec(currentPath);

  if (match) {
    const [url] = match;
    return exact ? currentPath === url : true;
  }

  return false;
}