本文整理汇总了TypeScript中angularfire2/angularfire2.firebaseAuthConfig函数的典型用法代码示例。如果您正苦于以下问题:TypeScript firebaseAuthConfig函数的具体用法?TypeScript firebaseAuthConfig怎么用?TypeScript firebaseAuthConfig使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了firebaseAuthConfig函数的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的TypeScript代码示例。
示例1: bootstrap
document.addEventListener('deviceready', () => {
bootstrap(EventFinderApp,
[
FIREBASE_PROVIDERS,
ROUTER_PROVIDERS,
defaultFirebase('https://sizzling-heat-4438.firebaseio.com'),
//storageBucket('gs://sizzling-heat-4438.appspot.com'),
firebaseAuthConfig({
method: AuthMethods.Redirect,
provider: AuthProviders.Password
}),
MyUsersService,
MyEventsService
]);
}, false);
示例2: main
export function main(): Promise<any> {
return bootstrap(AppComponent, [
...PLATFORM_PROVIDERS,
...ENV_PROVIDERS,
...AUTH_PROVIDERS,
...FIREBASE_PROVIDERS,
defaultFirebase({
apiKey: 'AIzaSyARs_f15bn2Zb0yBOB_MifZgufHTRzcY8A',
authDomain: 'ufc-oak.firebaseapp.com',
databaseURL: 'https://ufc-oak.firebaseio.com',
storageBucket: 'ufc-oak.appspot.com'
}),
firebaseAuthConfig({
provider: AuthProviders.Facebook,
method: AuthMethods.Popup,
scope: ['manage_pages', 'publish_pages']
}),
...APP_PROVIDERS,
])
.then(decorateComponentRef)
.catch(err => console.error(err));
}
示例3: enableProdMode
import {RouteConfig} from '@angular/router-deprecated';
import {MyUsersService} from './app/my-users.service';
import {MyEventsService} from './app/my-events.service';
import {
FIREBASE_PROVIDERS,
defaultFirebase,
AngularFire,
firebaseAuthConfig,
AuthMethods,
AuthProviders
} from 'angularfire2/angularfire2';
if (environment.production) {
enableProdMode();
}
//document.addEventListener('deviceready', () => {
bootstrap(EventFinderApp,
[
FIREBASE_PROVIDERS,
ROUTER_PROVIDERS,
defaultFirebase('https://sizzling-heat-4438.firebaseio.com'),
firebaseAuthConfig({
method: AuthMethods.Redirect,
provider: AuthProviders.Password
}),
MyUsersService,
MyEventsService
]);
//}, false);
示例4: defaultFirebase
import {FIREBASE_BASE_URL} from './firebase.constants';
import {FIREBASE_PROVIDERS, AuthMethods, firebaseAuthConfig, defaultFirebase} from 'angularfire2/angularfire2';
import {Auth} from './auth.service';
import {UsersStore} from './users.store.service';
import {AuthProviders} from 'angularfire2/angularfire2';
export const APP_FIREBASE_PROVIDERS = [
FIREBASE_PROVIDERS,
defaultFirebase(FIREBASE_BASE_URL),
firebaseAuthConfig({
method: AuthMethods.Password,
provider: AuthProviders.Password,
})
];
export const APP_AUTH_PROVIDERS = [
Auth, UsersStore
];
示例5: bootstrap
console.warn("DISPATCHED ACTION: ", val);
});
};
const stateLog: Middleware = (state: any) => {
return state.do((val: any) => {
console.info("NEW STATE: ", val);
});
};
bootstrap(WineCellarApp, [
ROUTER_PROVIDERS,
HTTP_PROVIDERS,
FIREBASE_PROVIDERS,
provide(APP_BASE_HREF, {useValue: "/"}),
provide(LocationStrategy, {useClass: HashLocationStrategy}),
defaultFirebase({
apiKey: "AIzaSyAq0nePnAWWJ_74KoCa8VIKrBkxqCB3eoU",
authDomain: "winecellar-50a24.firebaseapp.com",
databaseURL: "https://winecellar-50a24.firebaseio.com",
storageBucket: ""
}),
firebaseAuthConfig({
provider: AuthProviders.Password,
method: AuthMethods.Password,
remember: "default",
scope: ["email"]
}),
provideStore(store),
usePreMiddleware(actionLog),
usePostMiddleware(stateLog)
]);