Do you want to request a feature or report a bug?
Bug
What is the current behavior?
While running preact build, you will always get this deprecation warning:
DeprecationWarning: Chunk.modules is deprecated. Use Chunk.getNumberOfModules/mapModules/forEachModule/containsModule instead.
If the current behavior is a bug, please provide the steps to reproduce.
$ preact create default my-foobar --no-install
$ cd my-foobar && yarn
$ yarn build
What is the expected behavior?
There shouldn't be any deprecation message. Eventually, this will move from a soft-warning to a hard error.
Pretty certain that this line is the culprit. 馃憮
Ah yeah - maybe we can do an in check so it doesn't trigger the getter?
Pretty sure can just use chunk.getModules() instead. Most of the old webpack stuff is still there, just renamed with preference.
Opened issue in case someone wanted to contrib, else I'll hop on it soon :P
ah yeah - we control the webpack version anyway!
Hey,
If it's as simple as changing c.modules.slice() to c.getModules() then I'd be more than happy to create a PR now!
P.S. I love this tool! Thanks so much to all of you.
Yup! No guarantees here but I'm 90% sure that's all it needs~!