'use strict';

const index = require('./index-13fb62eb.js');

// const appRoute = '/:spaceId(/:membershipId)(/:viewId)';
const activateMembershipRoute = '/:spaceId(/:membershipConfigId)(/:membershipId)(/:viewId)';
function getRouteParams(pathname) {
  return new index.routeParser(activateMembershipRoute).match(pathname);
}
function getActivateMembershipRouteParams(pathname) {
  return new index.routeParser(activateMembershipRoute).match(pathname);
}
function buildRoute(spaceId, membershipConfigId, membershipId, viewId) {
  // console.log(new Route(appRoute).reverse({ spaceId, membershipId, viewId }));
  return new index.routeParser(activateMembershipRoute).reverse({ spaceId, membershipConfigId, membershipId, viewId });
}
// export function navigate(path: string) {
//   history.pushState({}, null, path);
// }
// export function redirect(path: string) {
// history.pushState({}, null, path)
// location.pathname = path;
// }

exports.buildRoute = buildRoute;
exports.getActivateMembershipRouteParams = getActivateMembershipRouteParams;
exports.getRouteParams = getRouteParams;
