Skip to content

Commit

Permalink
Use Object.keys as Object.values is not supported in node<7
Browse files Browse the repository at this point in the history
Object.values was introduced in 138b101
and it is not supported in node.js until version 7, so it's a mismatch
with what's declared in the `engines` section of package.json (node >= 6).
  • Loading branch information
klapec authored and fb55 committed Oct 9, 2020
1 parent 26e0d01 commit 98a0489
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/stringify.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,9 @@ const actionTypes: { [key: string]: string } = {
};

const charsToEscape = new Set([
...Object.values(actionTypes).filter(Boolean),
...Object.keys(actionTypes)
.map((typeKey) => actionTypes[typeKey])
.filter(Boolean),
":",
"[",
"]",
Expand Down

0 comments on commit 98a0489

Please sign in to comment.