-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathentry.js
More file actions
30 lines (27 loc) · 781 Bytes
/
entry.js
File metadata and controls
30 lines (27 loc) · 781 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
/**
* @remix-run/server-runtime v1.5.1
*
* Copyright (c) Remix Software Inc.
*
* This source code is licensed under the MIT license found in the
* LICENSE.md file in the root directory of this source tree.
*
* @license MIT
*/
'use strict';
Object.defineProperty(exports, '__esModule', { value: true });
function createEntryMatches(matches, routes) {
return matches.map(match => ({
params: match.params,
pathname: match.pathname,
route: routes[match.route.id]
}));
}
function createEntryRouteModules(manifest) {
return Object.keys(manifest).reduce((memo, routeId) => {
memo[routeId] = manifest[routeId].module;
return memo;
}, {});
}
exports.createEntryMatches = createEntryMatches;
exports.createEntryRouteModules = createEntryRouteModules;