本文整理汇总了TypeScript中angularfire2.defaultFirebase函数的典型用法代码示例。如果您正苦于以下问题:TypeScript defaultFirebase函数的具体用法?TypeScript defaultFirebase怎么用?TypeScript defaultFirebase使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了defaultFirebase函数的10个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的TypeScript代码示例。
示例1: constructor
</div>
<button (click)="addTask(newTask)" class=" ui positive right button" >
Add
</button>
</form>
`
})
class App {
tasks: FirebaseListObservable<any[]>;
//tasks: Observable<any[]>;
constructor(af: AngularFire){
this.tasks = af.list('/tasks');
}
addTask(task : HTMLInputElement): void {
console.log(`Adding article title: ${task.value} `);
this.tasks.add(task.value);
}
}
bootstrap(App, [
FIREBASE_PROVIDERS,
defaultFirebase('https://angular2-firebase-sample.firebaseio.com'),
]);
开发者ID:UsairimIsani,项目名称:angular2-firebase-sample,代码行数:29,代码来源:app.ts
示例2: ionicBootstrap
import { ionicBootstrap } from 'ionic-angular';
import { AppComponent } from './app.component';
import { FIREBASE_PROVIDERS, defaultFirebase } from 'angularfire2';
ionicBootstrap(
AppComponent,
[
FIREBASE_PROVIDERS,
defaultFirebase({
apiKey: "AIzaSyAtyYzFCPl5jKfMoMPlDMPnNfN8-HDKxkI",
authDomain: "mtkeasyinfo.firebaseapp.com",
databaseURL: "https://mtkeasyinfo.firebaseio.com",
storageBucket: "mtkeasyinfo.appspot.com",
})
],
{
iconMode:'ios',
pageTransition: 'ios',
backButtonIcon:'ios-arrow-back'
}
);
开发者ID:eriyu,项目名称:angular2-ionic2-webpack,代码行数:21,代码来源:main.ts
示例3: checkSession
}
checkSession(){
this.authService.session.subscribe(session =>{
this.rootPage = this.getPageInit(session);
})
}
getPageInit(session):any{
if (session) return TabsPage;
return LoginPage;
}
}
ionicBootstrap(MyApp, [
AuthService,
FIREBASE_PROVIDERS,
defaultFirebase({
apiKey: "AIzaSyCAJYjqPbfeBijP8skiDRz0mNn-Q3LYcuw",
authDomain: "instagram-8fe0a.firebaseapp.com",
databaseURL: "https://instagram-8fe0a.firebaseio.com",
storageBucket: "instagram-8fe0a.appspot.com",
}),
firebaseAuthConfig({
provider: AuthProviders.Password,
method: AuthMethods.Password
})
], {
mode: 'ios'
});
开发者ID:EscuelaIt,项目名称:class-10-demo,代码行数:30,代码来源:app.ts
示例4: enableProdMode
import { bootstrap } from '@angular/platform-browser-dynamic';
import { enableProdMode } from '@angular/core';
import { AppComponent, environment } from './app/';
import { FIREBASE_PROVIDERS, defaultFirebase } from 'angularfire2';
if (environment.production) {
enableProdMode();
}
bootstrap(AppComponent, [
FIREBASE_PROVIDERS,
// Initialize Firebase app
defaultFirebase({
})
]);
开发者ID:aaronksaunders,项目名称:afwithngcli,代码行数:16,代码来源:main.ts
示例5: enableProdMode
import { bootstrap } from '@angular/platform-browser-dynamic';
import { enableProdMode } from '@angular/core';
import { FlexchatAppComponent, environment } from './app/';
import { FIREBASE_PROVIDERS, defaultFirebase } from 'angularfire2';
if (environment.production) {
enableProdMode();
}
bootstrap(FlexchatAppComponent, [
FIREBASE_PROVIDERS,
defaultFirebase('https://flexchat.firebaseio.com/')
]);
开发者ID:ralon039,项目名称:firebase-angular2-demo,代码行数:13,代码来源:main.ts
示例6: enableProdMode
import {bootstrap} from '@angular/platform-browser-dynamic';
import {enableProdMode} from '@angular/core';
import {AppComponent, environment} from './app/';
import {appRouterProviders} from './app/app.routes';
import {FIREBASE_PROVIDERS, defaultFirebase} from 'angularfire2';
if (environment.production) {
enableProdMode();
}
bootstrap(AppComponent, [
FIREBASE_PROVIDERS,
// Initialize Firebase app
defaultFirebase({
apiKey: "AIzaSyD16CS8u7faSGfQqxYQcElkK5jBw9DgUWA",
authDomain: "crispycorpse-cc58e.firebaseapp.com",
databaseURL: "https://crispycorpse-cc58e.firebaseio.com",
storageBucket: "crispycorpse-cc58e.appspot.com"
}),
appRouterProviders
]);
开发者ID:aortyl,项目名称:crispy-writer,代码行数:21,代码来源:main.ts
示例7: enableProdMode
import { HTTP_PROVIDERS } from '@angular/http';
import { FIREBASE_PROVIDERS, defaultFirebase,
// AuthMethods,
// AuthProviders,
// firebaseAuthConfig
} from 'angularfire2';
import { FirebaseDataService } from './app/firebase-data.service';
if (environment.production) {
enableProdMode();
}
bootstrap(AppComponent, [
APP_ROUTER_PROVIDERS,
FirebaseDataService,
HTTP_PROVIDERS,
FIREBASE_PROVIDERS,
defaultFirebase({
apiKey: "AIzaSyDJplHLR1-jfcBB7_KyvgJ8MXawdG1Kl9E",
authDomain: "ur-coursesniper-e2a0d.firebaseapp.com",
databaseURL: "https://ur-coursesniper-e2a0d.firebaseio.com",
storageBucket: "",
}),
// firebaseAuthConfig({
// provider: AuthProviders.Anonymous,
// method: AuthMethods.Anonymous
// })
]);
开发者ID:raayanpillai,项目名称:ur-coursesniper,代码行数:30,代码来源:main.ts
示例8: enableProdMode
import { bootstrap } from '@angular/platform-browser-dynamic';
import { enableProdMode } from '@angular/core';
import { KarubaHelperAppComponent, environment } from './app/';
import { FIREBASE_PROVIDERS, defaultFirebase } from 'angularfire2';
if (environment.production) {
enableProdMode();
}
bootstrap(KarubaHelperAppComponent, [
FIREBASE_PROVIDERS,
defaultFirebase('https://karubahelper.firebaseio.com')
]);
开发者ID:TheWrightDev,项目名称:KarubaHelper,代码行数:13,代码来源:main.ts
示例9: bootstrap
import { bootstrap } from '@angular/platform-browser-dynamic';
import { FIREBASE_PROVIDERS, defaultFirebase, firebaseAuthConfig, AuthProviders, AuthMethods } from 'angularfire2';
import { App } from './app/authState.component';
import { disableDeprecatedForms, provideForms } from '@angular/forms';
bootstrap(App, [
FIREBASE_PROVIDERS,
disableDeprecatedForms(),
provideForms(),
// Initialize Firebase app
defaultFirebase({
apiKey: "AIzaSyD62AjtNiXO4eAhXTa6v-g1JmjVeT58tLY",
authDomain: "trivia-37669.firebaseapp.com",
databaseURL: "https://trivia-37669.firebaseio.com",
storageBucket: "trivia-37669.appspot.com",
}),
firebaseAuthConfig({
provider: AuthProviders.Password,
method: AuthMethods.Password,
remember: 'default',
scope: ['email']
})
]);
开发者ID:JSpell,项目名称:angular2-firebase,代码行数:24,代码来源:main.ts
示例10: enableProdMode
import { bootstrap } from '@angular/platform-browser-dynamic';
import { enableProdMode } from '@angular/core';
import { HTTP_PROVIDERS } from '@angular/http';
import { AppComponent, environment } from './app/';
import { FIREBASE_PROVIDERS, defaultFirebase } from 'angularfire2';
if (environment.production) {
enableProdMode();
}
bootstrap(AppComponent, [
FIREBASE_PROVIDERS,
HTTP_PROVIDERS,
// Initialize Firebase app
defaultFirebase({
apiKey: "AIzaSyB_8T55Bj61b0SNXfGl6xFm76nuaqvbLyI",
authDomain: "businessapp-35641.firebaseapp.com",
databaseURL: "https://businessapp-35641.firebaseio.com",
storageBucket: "businessapp-35641.appspot.com",
})
]);
开发者ID:loicbrigardis,项目名称:angular2-firebase,代码行数:22,代码来源:main.ts
注:本文中的angularfire2.defaultFirebase函数示例由纯净天空整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论