Skip to content

Instantly share code, notes, and snippets.

View thomascayne's full-sized avatar

Thomas Cayne thomascayne

View GitHub Profile
@thomascayne
thomascayne / database.module.ts
Created November 10, 2019 17:03 — forked from joseluisq/database.module.ts
Nest Database Module (Type ORM) with environment variables support
import { Module, Global, DynamicModule } from '@nestjs/common'
import { EnvModule } from './env.module'
import { EnvService } from './env.service'
import { TypeOrmModule } from '@nestjs/typeorm'
function DatabaseOrmModule (): DynamicModule {
const config = new EnvService().read()
return TypeOrmModule.forRoot({
type: config.DB_TYPE,
%reset-Button {
border: none;
margin: 0;
padding: 0;
width: auto;
overflow: visible;
background: transparent;
/* inherit font & color from ancestor */