New:Microsoft Teams Notifications Are Now Available in Socket.Learn more
Get Started

@0disoft/universal-config-engine-node

Package Overview
Dependencies
Maintainers
1
Versions
13
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@0disoft/universal-config-engine-node

Node.js JSON file, dotenv file, process env, and argv sources for Universal Config Engine.

Source
npmnpm
Version
1.0.0-rc.2
Version published
Weekly downloads
13
-85.87%
Maintainers
1
Weekly downloads
 
Created
Source

@0disoft/universal-config-engine-node

Bounded Node.js source adapters for Universal Config Engine. The package provides JSON file, simple dotenv file, process environment, and argv sources while keeping filesystem and process APIs outside the core package.

Install

npm install @0disoft/universal-config-engine-core @0disoft/universal-config-engine-node

Node.js >=24 and ESM are required.

Process Environment Source

import { resolveConfig } from "@0disoft/universal-config-engine-core";
import { createProcessEnvSource } from "@0disoft/universal-config-engine-node";

const envSource = createProcessEnvSource({
  descriptor: {
    id: "env",
    kind: "process-env",
    priority: 20,
    displayName: "environment"
  },
  env: process.env,
  mappings: [
    {
      externalName: "APP_PORT",
      sourceKind: "process-env",
      targetPath: ["service", "port"],
      parseAs: "number"
    }
  ]
});

const result = resolveConfig({ sources: [envSource] });
console.log(result.config.service.port);

File Sources

loadJsonFileSource and loadDotenvFileSource enforce byte limits. Set allowedRootPath to bind file loading to a canonical directory; the loader verifies the opened file identity before reading it. The dotenv parser is intentionally simple and does not perform shell expansion.

Process-env and argv adapters use explicit mappings and bounded entry counts. Strict unmapped-input diagnostics are opt-in.

See the compatibility contract and public API contract.

License

MIT

Keywords

config

FAQs

Package last updated on 15 Jul 2026

Related posts