@biorate/config 3.0.0 → 3.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -11,7 +11,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
11
11
  Object.defineProperty(exports, "__esModule", { value: true });
12
12
  exports.Config = void 0;
13
13
  const inversion_1 = require("@biorate/inversion");
14
- const lodash_1 = require("lodash");
14
+ const lodash_es_1 = require("lodash-es");
15
15
  const traverse_1 = __importDefault(require("traverse"));
16
16
  const template_1 = require("./template");
17
17
  const errors_1 = require("./errors");
@@ -41,7 +41,7 @@ let Config = class Config {
41
41
  throw new errors_1.UndefinedConfigPathError(path);
42
42
  return def;
43
43
  }
44
- const result = (0, lodash_1.get)(this.data, path);
44
+ const result = (0, lodash_es_1.get)(this.data, path);
45
45
  switch (typeof result) {
46
46
  case 'string':
47
47
  return this.template(result, def);
@@ -52,13 +52,13 @@ let Config = class Config {
52
52
  }
53
53
  }
54
54
  has(path) {
55
- return (0, lodash_1.has)(this.data, path);
55
+ return (0, lodash_es_1.has)(this.data, path);
56
56
  }
57
57
  set(path, value) {
58
- (0, lodash_1.set)(this.data, path, value);
58
+ (0, lodash_es_1.set)(this.data, path, value);
59
59
  }
60
60
  merge(data) {
61
- (0, lodash_1.merge)(this.data, data);
61
+ (0, lodash_es_1.merge)(this.data, data);
62
62
  }
63
63
  };
64
64
  exports.Config = Config;
@@ -5,7 +5,7 @@ var __decorate = (this && this.__decorate) || function (decorators, target, key,
5
5
  return c > 3 && r && Object.defineProperty(target, key, r), r;
6
6
  };
7
7
  import { injectable } from '@biorate/inversion';
8
- import { merge, get, has, set } from 'lodash';
8
+ import { merge, get, has, set } from 'lodash-es';
9
9
  import traverse from 'traverse';
10
10
  import { Template } from './template.js';
11
11
  import { UndefinedConfigPathError } from './errors.js';
@@ -1,4 +1,4 @@
1
- import { PropertyPath } from 'lodash';
1
+ import { PropertyPath } from 'lodash-es';
2
2
  export interface IConfig {
3
3
  get<T = unknown>(path: PropertyPath, def?: T): T;
4
4
  has(path: PropertyPath): boolean;
@@ -1,4 +1,4 @@
1
- import { PropertyPath } from 'lodash';
1
+ import { PropertyPath } from 'lodash-es';
2
2
  import { IConfig } from '../interfaces';
3
3
  export declare class Config implements IConfig {
4
4
  static readonly Template: {
@@ -1,5 +1,5 @@
1
1
  import { BaseError } from '@biorate/errors';
2
- import { PropertyPath } from 'lodash';
2
+ import { PropertyPath } from 'lodash-es';
3
3
  export declare class UndefinedConfigPathError extends BaseError {
4
4
  constructor(path: PropertyPath);
5
5
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@biorate/config",
3
- "version": "3.0.0",
3
+ "version": "3.1.0",
4
4
  "description": "Application configurator",
5
5
  "main": "./dist/cjs/index.js",
6
6
  "module": "./dist/esm/index.js",
@@ -45,11 +45,11 @@
45
45
  "keywords": [],
46
46
  "author": "llevkin",
47
47
  "license": "MIT",
48
- "gitHead": "b2400d06c44d0cac2dd01440a6075a100702c278",
48
+ "gitHead": "ca18c1129712e77a6ec8fb2033a54f94e5620ce0",
49
49
  "dependencies": {
50
50
  "@biorate/errors": "3.0.0",
51
- "@biorate/inversion": "3.0.0",
52
- "lodash": "^4.17.21",
51
+ "@biorate/inversion": "3.0.2",
52
+ "lodash-es": "^4.17.21",
53
53
  "traverse": "^0.6.6"
54
54
  },
55
55
  "devDependencies": {