traxxx-web/pages/scene/revisions/+route.js

20 lines
372 B
JavaScript
Raw Normal View History

import { match } from 'path-to-regexp';
const path = '/scene/revs/:sceneId/:slug?';
const urlMatch = match(path, { decode: decodeURIComponent });
export default (pageContext) => {
const matched = urlMatch(pageContext.urlPathname);
if (matched) {
return {
routeParams: {
sceneId: matched.params.sceneId,
domain: 'scenes',
},
};
}
return false;
};