mirror of
https://github.com/TryGhost/Ghost.git
synced 2024-12-15 03:12:54 +03:00
989d19837e
closes #3012 - Inject notification object into router - Listen to didTransition / observe currentPath to close notifications - Close notifications on successful save actions
17 lines
620 B
JavaScript
17 lines
620 B
JavaScript
import Notifications from 'ghost/utils/notifications';
|
|
|
|
var injectNotificationsInitializer = {
|
|
name: 'injectNotifications',
|
|
|
|
initialize: function (container, application) {
|
|
application.register('notifications:main', Notifications);
|
|
|
|
application.inject('controller', 'notifications', 'notifications:main');
|
|
application.inject('component', 'notifications', 'notifications:main');
|
|
application.inject('router', 'notifications', 'notifications:main');
|
|
application.inject('route', 'notifications', 'notifications:main');
|
|
}
|
|
};
|
|
|
|
export default injectNotificationsInitializer;
|