Skip to content

Commit

Permalink
Migrate off dot-prop
Browse files Browse the repository at this point in the history
  • Loading branch information
cressie176 committed Mar 13, 2024
1 parent 5b151ff commit 61eb195
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 4 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,10 @@ All notable changes to this project will be documented in this file.
The format is based on Keep a Changelog](https://keepachangelog.com/en/1.0.0/)
and this project adheres to Semantic Versioning](https://semver.org/spec/v2.0.0.html)

## Unreleased

- Migrate from [dot-prop](https://www.npmjs.com/package/dot-prop) to [has-value](https://www.npmjs.com/package/has-value), [get-value](https://www.npmjs.com/package/get-value) and [set-value](https://www.npmjs.com/package/set-value) due to dot-prop's move to ESM

## 4.0.0

- Replace logger.drain with logger.waitForTransports, which does not block subsequent messages from being logged
Expand Down
2 changes: 1 addition & 1 deletion lib/processors/human.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
const { EOL } = require("os");
const { has } = require("dot-prop");
const has = require("has-value");
const Chalk = require("chalk");
const stringify = require("json-stringify-safe");
const Level = require("../Level");
Expand Down
4 changes: 3 additions & 1 deletion lib/processors/index-fields.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
const { get, set, has } = require("dot-prop");
const has = require("has-value");
const get = require("get-value");
const set = require("set-value");

module.exports = (params = {}) => {
const { field = "fields", paths = [], reportComplexTypes = false } = params;
Expand Down
6 changes: 4 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,10 @@
"main": "index.js",
"dependencies": {
"chalk": "^4.1.2",
"dot-prop": "^6.0.1",
"json-stringify-safe": "^5.0.1"
"get-value": "^3.0.1",
"has-value": "^2.0.2",
"json-stringify-safe": "^5.0.1",
"set-value": "^4.1.0"
},
"devDependencies": {
"eslint": "^8.27.0",
Expand Down

0 comments on commit 61eb195

Please sign in to comment.