mirror of
https://github.com/TryGhost/Ghost.git
synced 2024-12-30 14:22:07 +03:00
ef4e4e8cc0
refs: bf0823c9a2
- continuing the work of splitting up the theme service into logical components
19 lines
667 B
JavaScript
19 lines
667 B
JavaScript
const helpers = require('../../services/theme-engine/handlebars/register');
|
|
const routingService = require('../../services/routing');
|
|
|
|
module.exports.getInstance = function getInstance() {
|
|
const appRouter = routingService.registry.getRouter('appRouter');
|
|
|
|
return {
|
|
helpers: {
|
|
register: helpers.registerThemeHelper.bind(helpers),
|
|
registerAsync: helpers.registerAsyncThemeHelper.bind(helpers)
|
|
},
|
|
// Expose the route service...
|
|
routeService: {
|
|
// This allows for mounting an entirely new Router at a path...
|
|
registerRouter: appRouter.mountRouter.bind(appRouter)
|
|
}
|
|
};
|
|
};
|