@adonisjs/config
Advanced tools
Comparing version 4.1.4-0 to 4.2.0-0
@@ -5,5 +5,6 @@ export declare class Config { | ||
all(): Record<any, any>; | ||
get<T extends any>(key: string, defaultValue?: any): T; | ||
has(key: string): boolean; | ||
get<T>(key: string, defaultValue?: any): T; | ||
defaults(key: string, value: any): void; | ||
set(key: string, value: any): void; | ||
} |
@@ -10,2 +10,5 @@ import lodash from '@poppinss/utils/lodash'; | ||
} | ||
has(key) { | ||
return lodash.has(this.#config, key); | ||
} | ||
get(key, defaultValue) { | ||
@@ -12,0 +15,0 @@ return lodash.get(this.#config, key, defaultValue); |
# The MIT License | ||
Copyright 2022 Harminder Virk, contributors | ||
Copyright (c) 2023 AdonisJS Framework | ||
@@ -5,0 +5,0 @@ Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the 'Software'), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: |
{ | ||
"name": "@adonisjs/config", | ||
"version": "4.1.4-0", | ||
"version": "4.2.0-0", | ||
"description": "Config management for AdonisJS framework", | ||
@@ -42,3 +42,3 @@ "main": "build/index.js", | ||
"@japa/spec-reporter": "^1.3.2", | ||
"@swc/core": "^1.3.27", | ||
"@swc/core": "^1.3.29", | ||
"@types/fs-extra": "^11.0.1", | ||
@@ -45,0 +45,0 @@ "@types/node": "^18.11.18", |
@@ -5,8 +5,4 @@ # @adonisjs/config | ||
<div align="center"> | ||
[![gh-workflow-image]][gh-workflow-url] [![npm-image]][npm-url] ![][typescript-image] [![license-image]][license-url] [![synk-image]][synk-url] | ||
</div> | ||
## Introduction | ||
@@ -13,0 +9,0 @@ Config provider to read AdonisJS application config values without directly relying on hard-coded paths. |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
7141
57
38