angularfire icon indicating copy to clipboard operation
angularfire copied to clipboard

AngularfirePerformance in main.ts

Open sanderschnydrig opened this issue 2 years ago • 1 comments

I tried to find information about this but couldn't find anything. Is it possible to use AngularfirePerformance to monitor the Angular bootstrapping in main.ts?

Using this code and @angular/fire at version ^7.6.1:

import { AngularFirePerformance } from '@angular/fire/compat/performance';
const performance = inject(AngularFirePerformance)

I'm getting this error:

core.mjs:4768 Uncaught Error: NG0203: inject() must be called from an injection context
    at injectInjectorOnly (core.mjs:4768:1)
    at ɵɵinject (core.mjs:4778:1)
    at 14431 (main.ts:25:27)
    at __webpack_require__ (bootstrap:19:1)
    at __webpack_exec__ (|groupOptions: {}|namespace object:239:1)
    at |groupOptions: {}|namespace object:239:1
    at __webpack_require__.O (chunk loaded:23:1)
    at |groupOptions: {}|namespace object:239:1
    at webpackJsonpCallback (jsonp chunk loading:71:1)
    at main.js:1:59

sanderschnydrig avatar Aug 25 '23 08:08 sanderschnydrig

This issue does not seem to follow the issue template. Make sure you provide all the required information.

google-oss-bot avatar Aug 25 '23 08:08 google-oss-bot