On Wed, Feb 18, 2015 at 8:04 AM, Edwin Park <edwin.p...@gmail.com> wrote:
> lol - you're right. I added ^:export to my entry point functions and all > is right with the world. :-) > > I noticed that if I remove the module for com.foo.common, the code in > there gets included in cljs_base.js in the compiler temporary output, but > there is no dead code elimination performed there. This may be expected, it > just means that I need to declare all my code in modules if I want it > minified. > This is not true. You do not need to declare all your code in modules. It is the presence of ^:export that prevents DCE. Also, about the explicit module dependencies declarations: it seems like it > should be possible to automatically generate these by analyzing the > namespace metadata. Is there a reason to force this to be explicitly > declared instead? As far as I can tell both Thomas Heller & Google have come to the conclusion that only explicit dependencies work reliably. I didn't bother exploring alternatives since I didn't think I would do any better :) David -- Note that posts from new members are moderated - please be patient with your first post. --- You received this message because you are subscribed to the Google Groups "ClojureScript" group. To unsubscribe from this group and stop receiving emails from it, send an email to clojurescript+unsubscr...@googlegroups.com. To post to this group, send email to clojurescript@googlegroups.com. Visit this group at http://groups.google.com/group/clojurescript.