The latest version of Webpack appears to behave differently than it did at the time the change was made.
technically still exported to avoid breaking existing builds
but tools like storybook should no longer find them because
of enumerable: false.
Webpack's require shim no longer respects enumerable: false, which causes Storybook to see exports it shouldn't.
This change forces properties to not be exported unless they explicitly have ^:export (or ^{:exportAs ""}) metadata.
I'm not sure which existing builds mentioned in @thheller's comment might be broken by this change.
If that's a concern, perhaps this change should be behind some sort of flag on the ns with the default behavior being the existing "export everything, but use enumerable: false" behavior.
(It's really only necessary for module consumers that expect all exports to mean something specific, like Storybook.)
Originally changed in https://github.com/thheller/shadow-cljs/commit/ec63c34ae493a7e75e9fe7d5f3ab7cadd1fecfe8 for #710
The latest version of Webpack appears to behave differently than it did at the time the change was made.
Webpack's
require
shim no longer respectsenumerable: false
, which causes Storybook to see exports it shouldn't.This change forces properties to not be exported unless they explicitly have
^:export
(or^{:exportAs ""}
) metadata.I'm not sure which existing builds mentioned in @thheller's comment might be broken by this change.
If that's a concern, perhaps this change should be behind some sort of flag on the
ns
with the default behavior being the existing "export everything, but use enumerable: false" behavior.(It's really only necessary for module consumers that expect all exports to mean something specific, like Storybook.)