How to use the @angular/router-deprecated.ROUTER_PROVIDERS function in @angular/router-deprecated

To help you get started, we’ve selected a few @angular/router-deprecated examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github chsakell / aspnet5-angular2-typescript / src / PhotoGallery / wwwroot / app / app.js View on Github external
__metadata('design:paramtypes', [membershipService_1.MembershipService, common_2.Location])
    ], AppRoot);
    return AppRoot;
}());
exports.AppRoot = AppRoot;
var AppBaseRequestOptions = (function (_super) {
    __extends(AppBaseRequestOptions, _super);
    function AppBaseRequestOptions() {
        _super.apply(this, arguments);
        this.headers = new http_1.Headers({
            'Content-Type': 'application/json'
        });
    }
    return AppBaseRequestOptions;
}(http_1.BaseRequestOptions));
platform_browser_dynamic_1.bootstrap(AppRoot, [http_1.HTTP_PROVIDERS, router_deprecated_1.ROUTER_PROVIDERS,
    core_1.provide(http_1.RequestOptions, { useClass: AppBaseRequestOptions }),
    core_1.provide(common_2.LocationStrategy, { useClass: common_2.HashLocationStrategy }),
    dataService_1.DataService, membershipService_1.MembershipService, utilityService_1.UtilityService])
    .catch(function (err) { return console.error(err); });
// ROUTER_BINDINGS: DO NOT USE HERE IF YOU WANT TO HAVE HASHLOCATIONSTRATEGY!! 
//# sourceMappingURL=app.js.map
github PowerShell / Phosphor / prototype / src / Phosphor-App / app / app.component.js View on Github external
var AppComponent = (function () {
    function AppComponent() {
        this.title = 'Phosphor';
    }
    AppComponent = __decorate([
        core_1.Component({
            selector: 'my-app',
            template: "\n    \n  ",
            styleUrls: ['app/css/app.component.css'],
            directives: [router_deprecated_1.ROUTER_DIRECTIVES],
            providers: [
                router_deprecated_1.ROUTER_PROVIDERS,
            ]
        }),
        router_deprecated_1.RouteConfig([
            {
                path: '/',
                name: 'Dashboard',
                component: dashboard_component_1.DashboardComponent,
                useAsDefault: true
            }
        ]), 
        __metadata('design:paramtypes', [])
    ], AppComponent);
    return AppComponent;
}());
exports.AppComponent = AppComponent;
github faxad / cartify / build / app.component.js View on Github external
var AppComponent = (function () {
    function AppComponent(auth) {
        this.auth = auth;
    }
    AppComponent.prototype.login = function () {
        this.auth.login();
    };
    AppComponent = __decorate([
        core_1.Component({
            selector: 'app-content',
            directives: [router_deprecated_1.ROUTER_DIRECTIVES, shop_item_list_component_1.ShopItemListComponent, cart_item_list_component_1.ItemCartComponent],
            providers: [router_deprecated_1.ROUTER_PROVIDERS, http_1.HTTP_PROVIDERS, auth_service_1.AuthService],
            template: "\n\t\t<nav class="\&quot;navbar">\n\t      <div class="\&quot;container\&quot;">\n\t        <div class="\&quot;navbar-header\&quot;">\n\t          <button aria-controls="\&quot;navbar\&quot;" aria-expanded="\&quot;false\&quot;" data-target="\&quot;#navbar\&quot;" data-toggle="\&quot;collapse\&quot;" class="\&quot;navbar-toggle" type="\&quot;button\&quot;">\n\t            <span class="\&quot;sr-only\&quot;">Toggle navigation</span>\n\t            <span class="\&quot;icon-bar\&quot;"></span>\n\t            <span class="\&quot;icon-bar\&quot;"></span>\n\t            <span class="\&quot;icon-bar\&quot;"></span>\n\t          </button>\n\t          <a href="\&quot;#\&quot;" class="\&quot;navbar-brand\&quot;">\n\t          \t<span aria-hidden="\&quot;true\&quot;" class="\&quot;glyphicon">Cartify</span>\n\t          </a>\n\t        </div>\n\t        <div class="\&quot;navbar-collapse" id="\&quot;navbar\&quot;">\n\t          <form class="\&quot;navbar-form">\n\t            <button class="\&quot;btn">\n\t            <span aria-hidden="\&quot;true\&quot;" class="\&quot;glyphicon"></span> Sign In\n\t            </button>\n\t            <button class="\&quot;btn">\n\t            <span aria-hidden="\&quot;true\&quot;" class="\&quot;glyphicon"></span> Sign Out\n\t            </button>\n\t          </form>\n\t        </div>\n\t      </div>\n\t    </nav>\n\t    <div class="\&quot;container\&quot;">\n\t    \t<div class="\&quot;starter-template\&quot;">\n\t    \t\t<br><br><br>\n\t    \t\t\n\t    \t</div>\n\t    </div>\n\t",
        }),
        router_deprecated_1.RouteConfig([
            { path: '/items', name: 'Items', component: shop_item_list_component_1.ShopItemListComponent, useAsDefault: true },
            { path: '/item/:id', name: 'Detail', component: shop_item_detail_component_1.ShopItemDetailComponent },
            { path: '/cart/:customerId', name: 'Cart', component: cart_item_list_component_1.ItemCartComponent }
        ]), 
        __metadata('design:paramtypes', [auth_service_1.AuthService])
    ], AppComponent);
    return AppComponent;
}());
exports.AppComponent = AppComponent;
github Cecildt / angular2-O365-desktop-app / src / boot / boot.js View on Github external
"use strict";
var core_1 = require('@angular/core');
var platform_browser_dynamic_1 = require('@angular/platform-browser-dynamic');
var router_deprecated_1 = require("@angular/router-deprecated");
var http_1 = require("@angular/http");
var common_1 = require('@angular/common');
require("rxjs/Rx");
var app_1 = require('../app/app');
var authHelper_1 = require("../authHelper/authHelper");
var profile_1 = require("../profile/profile");
platform_browser_dynamic_1.bootstrap(app_1.App, [authHelper_1.AuthHelper, profile_1.Profile, http_1.HTTP_PROVIDERS, router_deprecated_1.ROUTER_PROVIDERS, core_1.provide(common_1.APP_BASE_HREF, { useValue: '/' })]);
//# sourceMappingURL=boot.js.map
github videogular / videogular2 / examples / build / app.js View on Github external
{ path: '/single-media-player', name: 'SingleMediaPlayer', component: single_media_player_1.SingleMediaPlayer, useAsDefault: true },
            { path: '/multiple-media-player', name: 'MultipleMediaPlayer', component: multiple_media_player_1.MultipleMediaPlayer },
            { path: '/audio-player', name: 'AudioPlayer', component: audio_player_1.AudioPlayer },
            { path: '/bound-player', name: 'BoundPlayer', component: bound_player_1.BoundPlayer },
            { path: '/cue-points-player', name: 'CuePointsPlayer', component: cue_points_player_1.CuePointsPlayer },
            { path: '/video-360', name: 'Video360Player', component: video_360_player_1.Video360Player },
            { path: '/video-vr', name: 'VideoVrPlayer', component: video_vr_player_1.VideoVrPlayer },
            { path: '/**', redirectTo: ['SingleMediaPlayer'] }
        ]), 
        __metadata('design:paramtypes', [router_deprecated_1.Router, common_1.Location])
    ], VgDemo);
    return VgDemo;
}());
exports.VgDemo = VgDemo;
platform_browser_dynamic_1.bootstrap(VgDemo, [
    router_deprecated_1.ROUTER_PROVIDERS,
    core_1.bind(common_2.LocationStrategy).toClass(common_2.HashLocationStrategy)
]);
//# sourceMappingURL=app.js.map
github jumpserver / luna / luna / dist / ts / index.js View on Github external
var AppComponent = (function () {
    function AppComponent() {
        this.DataStore = service_1.DataStore;
    }
    AppComponent = __decorate([
        core_1.Component({
            selector: 'body',
            template: "<nav></nav>\n<span style="\&quot;display:none\&quot;" id="\&quot;liuzheng\&quot;">liuzheng</span>\n",
            directives: [nav_1.NavComponent, router_deprecated_1.ROUTER_DIRECTIVES],
            providers: [service_1.AppService, router_deprecated_1.ROUTER_PROVIDERS]
        }),
        router_deprecated_1.RouteConfig([
            { path: '/login', name: 'Login', component: login_1.LoginComponent },
            { path: '/', name: 'Index', component: IndexComponent },
            { path: '/aaa', name: 'Aaaa', component: IndexComponent },
            { path: '/bifrost', name: 'WorkboardComponent', component: WorkboardComponent },
            { path: '/hostedit', name: 'HostEdit', component: hostedit_1.HostEditComponent },
        ]), 
        __metadata('design:paramtypes', [])
    ], AppComponent);
    return AppComponent;
}());
exports.AppComponent = AppComponent;
github PowerShell / Phosphor / prototype / src / Phosphor-App / app / main.js View on Github external
"use strict";
var platform_browser_dynamic_1 = require('@angular/platform-browser-dynamic');
var router_deprecated_1 = require('@angular/router-deprecated');
var http_1 = require('@angular/http');
var app_component_1 = require('./app.component');
var noun_service_1 = require('./services/noun.service');
var verb_service_1 = require('./services/verb.service');
var collection_service_1 = require('./services/collection.service');
require('rxjs/Rx');
platform_browser_dynamic_1.bootstrap(app_component_1.AppComponent, [
    router_deprecated_1.ROUTER_PROVIDERS, noun_service_1.NounService, verb_service_1.VerbService, collection_service_1.CollectionService, http_1.HTTP_PROVIDERS
]);
//# sourceMappingURL=main.js.map
github dharmeshpipariya-zz / md2 / app / main.js View on Github external
"use strict";
const app_1 = require('./app');
const platform_browser_dynamic_1 = require("@angular/platform-browser-dynamic");
const core_1 = require("@angular/core");
const common_1 = require("@angular/common");
const router_deprecated_1 = require("@angular/router-deprecated");
platform_browser_dynamic_1.bootstrap(app_1.AppComponent, [
    router_deprecated_1.ROUTER_PROVIDERS,
    core_1.provide(common_1.LocationStrategy, { useClass: common_1.HashLocationStrategy })
]);

//# sourceMappingURL=main.js.map