Tensegritics / ClojureDart

Clojure dialect for Flutter and Dart
1.44k stars 91 forks source link

Allow hot reloading of dependencies brought in with `:local/root` #252

Closed conjurernix closed 1 year ago

conjurernix commented 1 year ago

Describe the bug When developing an app, with :local/root dependencies any changes to the code of the :local/root dependency are not picked up by hot reload

Does your problem persist after clj -M:cljd clean && flutter clean? Yes. To Reproduce Steps to reproduce the behavior:

  1. Create a Project, with two subprojects (or two separe projects in a different repo doesn't matter) each with it's own deps.edn file.
  2. Add one project to the other as a :local/root dependency
  3. Run the main project with clj -M:cljd flutter
  4. Make a change to the dependency project.
  5. Hot reload (or hot restart) your flutter instance.
  6. Change will not be there.

Expected behavior You would expect any changes to the :local/root dependency to be there after hot reloading

Additional context At the moment as a workaround, i have a :dev alias, refering to the src paths of the dependencies instead, and a :prod alias that actually brings dependencies by :local/root. Issue with this workaround is that any subdependencies listed in the local dependencies' deps.edn will not be added to the fetched, so you have to make sure that you have them listed in the parent project.