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

@contember/config-loader

Package Overview
Dependencies
Maintainers
5
Versions
262
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@contember/config-loader - npm Package Compare versions

Comparing version 0.12.0-beta.2 to 1.0.0-alpha.0

6

dist/src/config/Loader.js

@@ -16,3 +16,3 @@ "use strict";

async load(filename) {
const ext = path_1.extname(filename);
const ext = (0, path_1.extname)(filename);
if (!ext) {

@@ -27,3 +27,3 @@ throw new Loader.UnresolvedAdapterError(`File ${filename} does not have an extension.`);

const config = this.adapters[extWithoutDot].parse(file);
return await this.includeConfigs(config, path_1.dirname(filename));
return await this.includeConfigs(config, (0, path_1.dirname)(filename));
}

@@ -51,3 +51,3 @@ async loadString(content, adapter) {

return Merger_1.default.merge(...(await Promise.all((_include || []).map(async (file) => {
const nestedConfig = await this.load(path_1.join(baseDir, file));
const nestedConfig = await this.load((0, path_1.join)(baseDir, file));
if (typeof nestedConfig !== 'object' || nestedConfig === null) {

@@ -54,0 +54,0 @@ throw new Loader.InvalidConfigError(`Only object configs can be included`);

@@ -93,3 +93,3 @@ "use strict";

.map(([key, value]) => [key, resolveParametersInternal(value, [...path, key], parametersResolver)])
.reduce((result, [key, value]) => ({ ...result, [key]: value }), {});
.reduce((result, [key, value]) => value === undefined ? result : ({ ...result, [key]: value }), {});
}

@@ -96,0 +96,0 @@ return data;

{
"name": "@contember/config-loader",
"version": "0.12.0-beta.2",
"version": "1.0.0-alpha.0",
"license": "Apache-2.0",

@@ -12,3 +12,3 @@ "main": "dist/src/index.js",

"@types/js-yaml": "^4.0.1",
"@types/node": "^15.12.5"
"@types/node": "^17.0.5"
},

@@ -15,0 +15,0 @@ "dependencies": {

@@ -99,5 +99,5 @@ export type Path = (string | number)[]

.map(([key, value]: [string, any]) => [key, resolveParametersInternal(value, [...path, key], parametersResolver)])
.reduce((result, [key, value]) => ({ ...result, [key]: value }), {})
.reduce((result, [key, value]) => value === undefined ? result : ({ ...result, [key]: value }), {})
}
return data
}

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

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