Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@nestjs/config

Package Overview
Dependencies
Maintainers
2
Versions
56
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@nestjs/config - npm Package Compare versions

Comparing version 1.1.2 to 1.1.3

5

dist/config.service.d.ts

@@ -17,2 +17,3 @@ import { NoInferType, Path, PathValue } from './types';

}
declare type KeyOf<T> = T extends unknown ? string : keyof T;
export declare class ConfigService<K = Record<string, unknown>, WasValidated extends boolean = false> {

@@ -30,3 +31,3 @@ private readonly internalConfig;

*/
get<T = any>(propertyPath: keyof K): ExcludeUndefinedIf<WasValidated, T>;
get<T = any>(propertyPath: KeyOf<K>): ExcludeUndefinedIf<WasValidated, T>;
/**

@@ -46,3 +47,3 @@ * Get a configuration value (either custom configuration or process environment variable)

*/
get<T = any>(propertyPath: keyof K, defaultValue: NoInferType<T>): T;
get<T = any>(propertyPath: KeyOf<K>, defaultValue: NoInferType<T>): T;
/**

@@ -49,0 +50,0 @@ * Get a configuration value (either custom configuration or process environment variable)

2

dist/types/no-infer.type.d.ts

@@ -1,1 +0,1 @@

export declare type NoInferType<T> = [T][T extends any ? 0 : never];
export declare type NoInferType<T> = T extends unknown ? any : [T][T extends any ? 0 : never];
export declare type PathImpl<T, Key extends keyof T> = Key extends string ? T[Key] extends Record<string, any> ? `${Key}.${PathImpl<T[Key], Exclude<keyof T[Key], keyof any[]>> & string}` | `${Key}.${Exclude<keyof T[Key], keyof any[]> & string}` : never : never;
export declare type PathImpl2<T> = PathImpl<T, keyof T> | keyof T;
export declare type Path<T> = PathImpl2<T> extends string | keyof T ? PathImpl2<T> : keyof T;
export declare type Path<T> = T extends unknown ? any : PathImpl2<T> extends string | keyof T ? PathImpl2<T> : keyof T;
export declare type PathValue<T, P extends Path<T>> = P extends `${infer Key}.${infer Rest}` ? Key extends keyof T ? Rest extends Path<T[Key]> ? PathValue<T[Key], Rest> : never : never : P extends keyof T ? T[P] : never;
{
"name": "@nestjs/config",
"version": "1.1.2",
"version": "1.1.3",
"description": "Nest - modern, fast, powerful node.js web framework (@config)",

@@ -5,0 +5,0 @@ "author": "Kamil Mysliwiec",

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc