Start dev server middleware alongside Storybook #787
Merged
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.
Doing some QOL storybook uplift before the storybook 7 release.
Storybook will inject middleware found in
.storybook/middleware.js
into its own middleware stack. This is an intentionally undocumented feature, but given that it has been stable for at least 5 years, I don't think it will disappear any time soon, so I'm happy to depend on it.Adding this feature neatly solves the issue where the new
seekJobs
braid theme needs a webfont. Shared web assets exposes a middleware for serving the webfont locally, and with this feature the middleware will also be available when running storybook.This feature has also been requested by teams that would like to run other middleware alongside storybook.
I also did a small docs pass to add some subheadings to the storybook docs, as well as document this new feature. Will do another docs pass for storybook 7.
Finally, I moved the
node-fetch
dev dep from sku to test utils, where it belongs.