using matomo in application and wantes to pass dynamic parameters to Matomodule.forRoot method in angular. getting dynamic configuration assest

Hi I ran into a problem,

using Matomo for analytics and in app.module.ts configuration it needs like below –

MatomoModule.forRoot(
{

peop1: value1,
peop1: value2,
peop1: value3,
})

Also I am fetching config.json from assest before angular application starts up.

Now the problem is value1, value2 and value3 should be coming from config.json but before the promise get resolve app.module external module get initialized.

How to pass dynamic value to forRoot method in this case.

Tried APP_INIT provider but imports modules are initialized before APP_INIT promise is resolved.