New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More

@automapper/nestjs

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@automapper/nestjs

AutoMapper TypeScript NestJS integration


Version published
Maintainers
1
Created

@automapper/nestjs

This is a NestJS module to integrate @automapper with NestJS.

Installation

npm i @automapper/nestjs

or with yarn:

yarn add @automapper/nestjs
peerDependencies

@automapper/nestjs depends on @automapper/core and @automapper/types (and some other @nestjs/* libraries but you should already have these installed in a NestJS application)

npm i @automapper/core
npm i --save-dev @automapper/types

or with yarn:

yarn add @automapper/core
yarn add --dev @automapper/types

Usage

Call AutomapperModule.forRoot() and provide some options to initialize the Mapper object(s).

@Module({
  imports: [
    AutomapperModule.forRoot({
      options: [{ name: '', pluginInitializer: classes }],
      singular: true,
    }),
  ],
})
export class AppModule {}

AutomapperModule is a Global module so when Mapper object(s) are initialized, they're available across the application.

Read more about this on the documentation site

FAQs

Package last updated on 26 Feb 2021

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts