0.0.2 • Published 9 months ago

@cubetiq/vstore v0.0.2

Weekly downloads
-
License
ISC
Repository
github
Last release
9 months ago

vStore SDK for JS/TS

A simple way to use environment variables in Node.js and other environments.

  • Load all configs
  • Cache support
  • Namespace support
  • Load to process.env support

Usages

import { VStore } from '@cubetiq/vstore';

const PROJECT_ID = 'xx';
const API_KEY = 'vs_xx';

const sdk = VStore.createWith(PROJECT_ID, API_KEY);

sdk.config()
    .waitForReady()
    .then(() => {
        console.log(sdk.config().isReady());
        console.log(sdk.config().getByKey('app.name'));
        console.log(sdk.config().get('common', 'app.name'));
    })
    .catch((err) => {
        console.error(err);
    });

Contributors

0.0.2

9 months ago

0.0.1

12 months ago