Socket
Socket
Sign inDemoInstall

conf

Package Overview
Dependencies
Maintainers
0
Versions
58
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

conf - npm Package Compare versions

Comparing version 13.0.0 to 13.0.1

13

dist/source/index.js

@@ -96,2 +96,9 @@ /* eslint-disable @typescript-eslint/naming-convention, @typescript-eslint/no-unsafe-return */

const store = Object.assign(createPlainObject(), options.defaults, fileStore);
if (options.migrations) {
if (!options.projectVersion) {
throw new Error('Please specify the `projectVersion` option.');
}
this._migrate(options.migrations, options.projectVersion, options.beforeEachMigration);
}
// We defer validation until after migrations are applied so that the store can be updated to the current schema.
this._validate(store);

@@ -107,8 +114,2 @@ try {

}
if (options.migrations) {
if (!options.projectVersion) {
throw new Error('Please specify the `projectVersion` option.');
}
this._migrate(options.migrations, options.projectVersion, options.beforeEachMigration);
}
}

@@ -115,0 +116,0 @@ get(key, defaultValue) {

{
"name": "conf",
"version": "13.0.0",
"version": "13.0.1",
"description": "Simple config handling for your app or module",

@@ -5,0 +5,0 @@ "license": "MIT",

@@ -67,3 +67,3 @@ # conf

Under the hood, the JSON Schema validator [ajv](https://github.com/epoberezkin/ajv) is used to validate your config. We use [JSON Schema draft-07](https://json-schema.org/latest/json-schema-validation.html) and support all [validation keywords](https://github.com/epoberezkin/ajv/blob/master/KEYWORDS.md) and [formats](https://github.com/epoberezkin/ajv#formats).
Under the hood, the JSON Schema validator [ajv](https://ajv.js.org/json-schema.html) is used to validate your config. We use [JSON Schema draft-2020-12](https://json-schema.org/draft/2020-12/release-notes) and support all validation keywords and formats.

@@ -70,0 +70,0 @@ You should define your schema as an object where each key is the name of your data's property and each value is a JSON schema used to validate that property. See more [here](https://json-schema.org/understanding-json-schema/reference/object.html#properties).

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