Open danprince opened 4 years ago
No worries, moving to the proper repo
Yup, this is expected behavior for now (there's no way right now to tell what was and wasn't bundled after the bundler ran, so we default to include everything).
We should add a feature to the plugin to analyze which files were included in the final bundle, and delete them from the build directory. I think that there are straightforward Webpack hooks that we can hook into for this, but I'm not sure about Parcel.
It looks like the bundling step from
@snowpack/plugin-parcel
doesn't do any kind of cleanup after bundling, so the build directory ends up containing the bundled/fingerprinted assets and the original output fromsnowpack build
.I think it'd make more sense to file this issue wherever that plugin code lives, but I can't find the repo!
Produces something like:
After bundling, I want to deploy the
build
dir, but I don't really want to deploybuild/web_modules
orbuild/_dist_
because they aren't going to be used.Ideally the bundling plugins would output the bundled version to a separate directory (I think Parcel already does this with a
.build
directory) then cleanbuild
and copy the contents across.