# @excsn/c5store

> All encompassing configuration store to meet all needs.

Latest version **1.0.3** (published 2022-08-10) · MPL-2.0 license · 0 weekly downloads

## Install

```sh
npm install @excsn/c5store
pnpm add @excsn/c5store
yarn add @excsn/c5store
bun add @excsn/c5store
```

## Health

**Score 35/100 (D)** — status: abandoned.

Positive: esm support; no vulnerabilities; high maintenance score.

Warnings: low downloads; no types.

Negative: abandoned.

## Facts

| | |
|---|---|
| Version | 1.0.3 |
| Published | 2022-08-10 |
| First published | 2019-08-18 |
| Weekly downloads | 0 |
| License | MPL-2.0 |
| TypeScript types | none |
| Module format | ESM + CommonJS |
| Dependencies | 9 |
| Unpacked size | 128.1 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 0 |
| Author | Norm O |
| Maintainers | exforte |

## Links

- npm: https://www.npmjs.com/package/@excsn/c5store
- Repository: https://github.com/normano/c5store
- Homepage: https://github.com/normano/c5store#readme
- Issues: https://github.com/normano/c5store/issues
- npm.io page: https://npm.io/package/@excsn/c5store

## Dependencies (9)

- [dequal](https://npm.io/package/dequal.md) ^2.0.2
- [js-yaml](https://npm.io/package/js-yaml.md) ^4.1.0
- [fs-extra](https://npm.io/package/fs-extra.md) ^10.0.0
- [lodash.merge](https://npm.io/package/lodash.merge.md) ^4.6.2
- [node-schedule](https://npm.io/package/node-schedule.md) ^2.1.0
- [@excsn/jumplist](https://npm.io/package/@excsn/jumplist.md) ^0.3.5
- [@excsn/ecies_25519](https://npm.io/package/@excsn/ecies_25519.md) ^0.1.2
- [@teppeis/multimaps](https://npm.io/package/@teppeis/multimaps.md) ^2.0.0
- [string-natural-compare](https://npm.io/package/string-natural-compare.md) ^3.0.1

## Recent versions

- 1.0.3 (latest) — 2022-08-10
- 1.0.2 — 2022-08-09
- 1.0.0 — 2022-08-09
- 1.0.0-prerelease.5 — 2021-12-05
- 1.0.0-prerelease.4 — 2021-11-29
- 1.0.0-prerelease.3 — 2021-09-18
- 1.0.0-prerelease.2 — 2020-02-09
- 1.0.0-prerelease.1 — 2019-12-03
- 1.0.0-alpha4 — 2019-09-17
- 1.0.0-alpha3 — 2019-08-18

## README

# C5Store for NodeJS

C5Store is an all encompassing configuration store. The idea is to have one place to query and dump configuration, secrets and etc.

Read more about it: https://github.com/normano/c5store

# Getting Started

To start using C5Store in yor NodeJS application.

1. Install as a dependency
- `npm i @excsn/c5store`
- `yarn add @excsn/c5store`

2. Import with 

`import {createC5Store, defaultConfigFiles, C5Store, C5StoreMgr} from "@excsn/c5store";`

3. Create a config folder with common.yaml

    foo: bar
    example:
     test:
      it: "today"
      my: 42

4. Create and use the store

   let [c5Store, c5StoreMgr] = await createC5Store(configFilePaths: ["common.yaml"]);
   
   // Use the store
   
   let data = c5Store.get("foo");

   // Use to get nested data by branching.
   
   let nestedData = c5Store.branch("example.test").get("my");

   // Inspect where you are on a branch
   
   console.log(c5Store.branch("example.test").currentKeyPath);

## Examples 
Look at the [example](example) folder for an implementation and how to use the C5FileValueProvider to get data from a file.

---
_Source: https://npm.io/package/@excsn/c5store · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
