In app.module.ts
import { provideFunctions, getFunctions } from '@angular/fire/functions';
@NgModule({
imports: [
...
provideFirebaseApp(() => initializeApp(environment.firebase)),
provideFunctions(() => getFunctions()),
],
In my app.component
export class AppComponent {
constructor(private fns: Functions) {}
hello() {
httpsCallable(
this.fns,
'test'
)('hello world').then(() => console.log('complete'));
}
}
This code works perfectly fine but why do I get this syntax error
from Unknown Syntax Error when implementing Cloud Functions in the new AngularFire 7 (Firebase 9)
No comments:
Post a Comment