mirror of
https://github.com/TryGhost/Ghost.git
synced 2024-12-11 22:13:20 +03:00
9b54ed0689
refs #9192 - Instead of `setupRoutes` function in apps that gets passed a router, there is now a registerRouter function as part of the proxy - Moved towards a route service, which will know about all routes - Using classes to abstract away shared behaviour Notes: - changing the app proxy didn't result in a test failure! - structure of route service is totally new and may change a lot yet
12 lines
345 B
JavaScript
12 lines
345 B
JavaScript
var router = require('./lib/router'),
|
|
registerHelpers = require('./lib/helpers'),
|
|
config = require('../../config');
|
|
|
|
module.exports = {
|
|
activate: function activate(ghost) {
|
|
registerHelpers(ghost);
|
|
|
|
ghost.routeService.registerRouter('*/' + config.get('routeKeywords').amp + '/', router);
|
|
}
|
|
};
|