本文整理匯總了TypeScript中angularfire2.AngularFireModule.initializeApp方法的典型用法代碼示例。如果您正苦於以下問題:TypeScript AngularFireModule.initializeApp方法的具體用法?TypeScript AngularFireModule.initializeApp怎麽用?TypeScript AngularFireModule.initializeApp使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類angularfire2.AngularFireModule
的用法示例。
在下文中一共展示了AngularFireModule.initializeApp方法的10個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的TypeScript代碼示例。
示例1: beforeEach
beforeEach(async(() => {
TestBed.configureTestingModule({
imports: [
AngularFireModule.initializeApp(environment.firebase)
],
declarations: [ MainHomeComponent ]
})
.compileComponents();
}));
示例2: beforeEach
beforeEach(() => {
TestBed.configureTestingModule({
imports: [
RouterTestingModule,
AngularFireModule.initializeApp(environment.firebase)
],
providers: [AuthGuard]
});
});
示例3: beforeEach
beforeEach(() => TestBed.configureTestingModule({
imports: [
FormsModule,
ReactiveFormsModule,
AngularFireModule.initializeApp(firebaseConfig, firebaseAuthConfig),
],
providers: [
HomeComponent,
],
}));
示例4: beforeEach
beforeEach(async(() => {
TestBed.configureTestingModule({
imports: [ MaterialModule, RouterTestingModule,
AngularFireModule.initializeApp(firebaseConfig)
],
providers: [ ProjectService, TaskService, DialogService, AngularFire ],
declarations: [ UploaderComponent ]
})
.compileComponents();
}));
示例5: beforeEach
beforeEach(async(() => {
TestBed.configureTestingModule({
imports: [
RouterTestingModule,
FormsModule,
AngularFireModule.initializeApp(environment.firebase)
],
declarations: [ LoginComponent ]
})
.compileComponents();
}));
示例6: beforeEach
beforeEach(() => {
TestBed.configureTestingModule({
imports: [
AngularFireModule.initializeApp(COMMON_CONFIG),
AngularFireStorageModule
]
});
inject([FirebaseApp, AngularFireStorage], (app_: FirebaseApp, _storage: AngularFireStorage) => {
app = app_;
afStorage = _storage;
})();
});
示例7: beforeEach
beforeEach(() => {
TestBed.configureTestingModule({
imports: [
AngularFireModule.initializeApp(COMMON_CONFIG, '[DEFAULT]'),
AngularFireDatabaseModule
]
});
inject([FirebaseApp, AngularFireDatabase], (app_: FirebaseApp, _db: AngularFireDatabase) => {
app = app_;
db = _db;
})();
});
示例8: beforeEach
beforeEach(() => {
TestBed.configureTestingModule({
imports: [
AngularFireModule.initializeApp(COMMON_CONFIG),
AngularFireFunctionsModule
]
});
inject([FirebaseApp, AngularFireFunctions], (app_: FirebaseApp, _fn: AngularFireFunctions) => {
app = app_;
afFns = _fn;
})();
});
示例9: beforeEach
beforeEach(() => {
TestBed.configureTestingModule({
imports: [
AngularFireModule.initializeApp(COMMON_CONFIG),
AngularFirestoreModule.enablePersistence()
]
});
inject([FirebaseApp, AngularFirestore], (_app: FirebaseApp, _afs: AngularFirestore) => {
app = _app;
afs = _afs;
})();
});
示例10: beforeEach
beforeEach(() => {
TestBed.configureTestingModule({
imports: [
AngularFireModule.initializeApp(COMMON_CONFIG, FIREBASE_APP_NAME),
AngularFireDatabaseModule
]
});
inject([FirebaseApp, AngularFireDatabase, NgZone], (app_: FirebaseApp, _db: AngularFireDatabase, _zone: NgZone) => {
app = app_;
db = _db;
zone = _zone;
})();
});