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.
I tried to update my app to Node 18, and found that the test-runner started to fail. I learned it was because of a change in Node 17 to no longer sort the results of
getaddrinfo
to prefer ipv4 addresses. This means on some machines after node 17,localhost
no longer resolves to127.0.0.1
.Therefore, running
http-server storybook-static --port 6006
and thentest-storybook
will no longer work, becauselocalhost
is looking for an ipv6 address, and http-server sets up on ipv4.As a workaround, I can use
--url http://127.0.0.1:6006
, but that seems like it shouldn't be necessary.So this change looks for
127.0.0.1
explicitly as the default, and updates the documentation to reference it that way as well. I tested this back to node 16 and of course it works fine there too.This should make it a bit easier for folks to upgrade to node 18 without nasty surprises.
Version
Published prerelease version:
v0.10.0-next.7
Changelog
🚀 Enhancement
🐛 Bug Fix
📝 Documentation
Authors: 7