我試圖創建一個使用AngularFire2AngularFire2錯誤「的ReferenceError:火力點沒有定義」
這是引發錯誤的代碼與電子郵件/密碼的用戶,當我點擊我的註冊組件的提交按鈕:
firebase.auth().createUserWithEmailAndPassword(this.signupForm.value.email, this.signupForm.value.password).catch(function(error) {
alert(error.message);
});
從的package.json版本:
angular: "^2.3.1",
"angularfire2": "^2.0.0-beta.7",
"firebase": "^3.6.6"
我一直有麻煩實現電子郵件/通AUTH從一開始就angularfire2,我已經搜查˚F或超過一個半小時尋找這個問題的答案(其中,似乎沒有很多的信息/支持angularfire2呢?)
請幫助! 我還在學習,這真的讓我難住。
這裏是完全錯誤的控制檯:
vendor.bundle.js:46373 ReferenceError: firebase is not defined
at SignupComponent.webpackJsonp.806.SignupComponent.signup (http://localhost:4200/main.bundle.js:601:9)
at CompiledTemplate.proxyViewClass.View_SignupComponent0.handleEvent_0 (/AppModule/SignupComponent/component.ngfactory.js:152:34)
at CompiledTemplate.proxyViewClass.<anonymous> (http://localhost:4200/vendor.bundle.js:65473:37)
at SafeSubscriber.schedulerFn [as _next] (http://localhost:4200/vendor.bundle.js:79924:36)
at SafeSubscriber.__tryOrUnsub (http://localhost:4200/vendor.bundle.js:52413:16)
at SafeSubscriber.next (http://localhost:4200/vendor.bundle.js:52362:22)
at Subscriber._next (http://localhost:4200/vendor.bundle.js:52315:26)
at Subscriber.next (http://localhost:4200/vendor.bundle.js:52279:18)
at EventEmitter.Subject.next (http://localhost:4200/vendor.bundle.js:52079:25)
at EventEmitter.emit (http://localhost:4200/vendor.bundle.js:79898:76)
at FormGroupDirective.onSubmit (http://localhost:4200/vendor.bundle.js:81620:23)
at Wrapper_FormGroupDirective.handleEvent (/ReactiveFormsModule/FormGroupDirective/wrapper.ngfactory.js:42:34)
at CompiledTemplate.proxyViewClass.View_SignupComponent0.handleEvent_0 (/AppModule/SignupComponent/component.ngfactory.js:150:42)
at CompiledTemplate.proxyViewClass.<anonymous> (http://localhost:4200/vendor.bundle.js:65473:37)
at HTMLFormElement.<anonymous> (http://localhost:4200/vendor.bundle.js:34579:53)
也請張貼你的錯誤。 –
我加了 –