export const getQueryParam = (paramName: string) => {
  const search = window.location.search;
  const params = new URLSearchParams(search);
  return params.get(paramName);
};

export const parseQueryParams = () => {
  const params = new URLSearchParams(window.location.search);
  const result: Record<string, string> = {};

  for (const [key, value] of params.entries()) {
    result[key] = value;
  }

  return result;
}