2.1.2 • Published 3 months ago

sf-env-vars v2.1.2

Weekly downloads
5
License
ISC
Repository
-
Last release
3 months ago

sf-env-vars

A simple npm package for accessing Salesforce-Env-Vars.

Usage

  1. Install

npm install sf-env-vars

  1. Define an ENV Class. The property names should match the ENV_VAR DeveloperName and must be assigned to null:
    export class Env {
        public FOO: string = null; 
        public BAR: number = null;
    }
  1. Load & Use
    import {load} from 'sf-env-vars';
    const vars = await load(Env);
    console.log(vars.FOO, vars.BAR);

Note: Currently uses ts-force as a peer dependency to connect & query salesforce. Will likely refactor in the future to accept a connection (and use more lightwieght client like axios).

2.1.2

3 months ago

2.1.1

3 months ago

2.1.0

4 years ago

2.0.0

5 years ago

1.0.1

5 years ago

1.0.0

5 years ago