All files / libs/vendors/carbone/src/lib carbone.config.ts

91.66% Statements 11/12
100% Branches 1/1
100% Functions 1/1
91.66% Lines 11/12

Press n or j to go to the next uncovered block, b, p or k for the previous block.

1 2 3 4 5 6 7 8 9 10 11 12 131x 1x 1x 1x 1x   1x 1x 1x 1x 1x 1x  
import { Inject } from '@nestjs/common';
import { registerAs, type ConfigType } from '@nestjs/config';
import * as env from 'env-var';
 
export const carboneConfig = registerAs('carbone', () => ({
  baseUrl: env.get('CARBONE_BASE_URL').default('http://localhost:4000/').asString(),
}));
 
const CARBONE_CONFIG = carboneConfig.KEY;
export const InjectCarboneConfig = () => Inject(CARBONE_CONFIG);
 
export type CarboneConfig = ConfigType<typeof carboneConfig>;