Closed nistvan86 closed 10 years ago
Hi,
Unfortunately, there is no way to know if a package is used only on the server or client side.
To minimize this problem, you can split your project in two: one for the server side, and another with the client stuff. But since bloodless depends on packages that works on the both sides (for example: di and route_hierarchical), you'll still see packages like browser copied to the server build.
Maybe in the future, the Dart SDK provides an easy and safe way to "compile" your server code to a single file, removing unused code. But until then, there is no definitive solution to this problem.
I see. Thanks for explaining.
Hi!
I've just found bloodless recently. I really like the whole concept behind, thanks for developing it!
I have created a Grinder based build script following the example in the readme to test the build. I've noticed that Grinder copies even client side dependencies to
build/bin/packages
, for example thebrowser
package which is meaningless on the server side. Client side dependencies are built as expected, bloddless doesn't gets copied tobuild/web/packages
.