Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

issues with modules in cljs task. Creates an empty file. #196

Open
mariuene opened this issue Nov 22, 2018 · 4 comments
Open

issues with modules in cljs task. Creates an empty file. #196

mariuene opened this issue Nov 22, 2018 · 4 comments

Comments

@mariuene
Copy link

mariuene commented Nov 22, 2018

Hey. I have an issue with the cljs task.

Using the cljs compiler from adzerk/boot-cljs with the :modules option added, the modules will still be in the cljs_base.js file when compiled, and not in their own assigned files.

 :compiler-options {...
                    :modules {:app  {:output-to "bar/app/main.js"  
                                     :entries '#{test.app.main}}
                              :cool {:output-to "bar/cool/cool.js"
                                     :entries '#{test.cool.cool}}}}

When adding these compiler options to the cljs task, the assigned .js files for the modules will be created, but they will not contain any code.

Using these options directly with the cljs.build.api/build function will work as wanted.

I've set up a dummy project with some example code to display the bug https://github.com/mariuene/cljs-boot-modules-issue

@mariuene
Copy link
Author

mariuene commented Nov 23, 2018

It seems to work for one module when you have a .cljs.edn file.

@mariuene
Copy link
Author

I updated the dummy repo.
Looks like when you have multiple .cljs.edn files and and you want to have a module for each, the only module that will be created is for the first .cljs.edn file in alphabetical order. The other(s) will be added to the base_cljs.js file.

@DjebbZ
Copy link
Contributor

DjebbZ commented Feb 4, 2019

Is it still relevant since I managed to get it working ? Will show you and the rest of the team soon.

@mariuene
Copy link
Author

mariuene commented Feb 6, 2019

I haven't really looked into this more, but if you have something that works I would be more than happy to have a look at it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants