Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Implements #225
Notes
Supported Node Version
I noticed the json5 package supports only Node
>=6
but this package supports>=4
.However, I noticed there were already warnings about other packages only supporting Node 6.
I was also not able to get tests running using Node 4.
One Node 6 test is failing as well, but Node 6 can at least run tests.
(Tested from scratch without my changes.)
Your Travis build history is also not loading for me, so I'm not sure if this is expected.
Removed read-pkg
I have removed
read-pkg
since it does not supportpackage.json5
.I cannot submit a PR to that repo since newer versions do not support Node 4/6, and I think it will require an API redesign.
This is a fairly simple package and easy to replace.
It mostly relies on two other packages:
load-json-file
andnormalize-package-data
.I have installed the same versions in the version of
read-pkg
that was previously used.Tests
I have tried my best at writing tests for this change.
I don't think it is perfectly in line with the style of your other tests, but this was the simplest way I could see to test it.
If you have other ideas for tests, feel free to give guidance or change my tests when merging.