Hello. I am new to supertokens. I am using nest js...
# general
p
Hello. I am new to supertokens. I am using nest js with supertokens. As documentation auth.module has static function
Copy code
static forRoot({ connectionURI, apiKey, appInfo }: AuthModuleConfig): DynamicModule {
      return {
        providers: [
          {
            useValue: {
              appInfo,
              connectionURI,
              apiKey,
            },
            provide: ConfigInjectionToken,
          },
        ],
        exports: [],
        imports: [],
        module: AuthModule,
      };
    }
And Then I have used this method to to app.module something like this
Copy code
imports: [
    AuthModule.forRoot({
      connectionURI: process.env.AUTH_CONNECTION_URI,
      appInfo: {
        appName: "canopy",
        apiDomain: process.env.API_DOMAIN,
        websiteDomain: process.env.WEBSITE_DOMAIN,
        apiBasePath: "/auth/",
        websiteBasePath: "/",
      },
    }),
    ConfigModule.forRoot({
      isGlobal: true,
      load: [config],
    })
  ],
My question is how can i use configService to get the env values in AuthModule.forRoot function ?
2 Views