1.4.1 • Published 4 months ago

@codemaskjs/nestjs-config v1.4.1

Weekly downloads
-
License
MIT
Repository
github
Last release
4 months ago

Codemask Nestjs Config Module

How to Install

Required peer dependencies

!NOTE If your project already uses @nestjs/common, class-validator and/or class-transformer - then skip installing mentioned peer dependencies.

$ yarn add @nestjs/common class-validator class-transformer

Adding package to your project

$ yarn add @codemaskjs/nestjs-config

Configuration

Configuring ConfigModule for root

For providing globally available configs, use the example from below:

import { Module } from '@nestjs/common'
import { ConfigModule } from '@codemaskjs/nestjs-config'

@Module({
    imports: [
        ConfigModule.forRoot()
        // or
        ConfigModule.forRoot([<your config class>, ...])
        // or
        ConfigModule.forFeature([<your config class>, ...])
        // or
        ConfigModule.forTest(<your config class>, <optional and partial overrides>)
    ]
})
export class MailerModule {}

Examples

  1. Config Class

To be updated

  1. Config Module

Using forRoot

To be updated

Using forFeature

To be updated

Using forFeature with TypeOrm

  1. Config Service

To be updated

1.4.1

4 months ago

1.3.2

4 months ago

1.4.0

4 months ago

1.3.1

4 months ago

1.3.0

4 months ago

1.2.2

5 months ago

1.2.1

5 months ago

1.2.0

6 months ago

1.1.0

6 months ago

1.0.2

6 months ago

1.0.1

6 months ago