clj-commons / potemkin

some ideas which are almost good
572 stars 53 forks source link

docs: add caveat about import-vars? #68

Open lread opened 1 year ago

lread commented 1 year ago

Some time ago I merged rewrite-cljs v0 and rewrite-clj v0 to create rewrite-clj v1.

Rewrite-clj v0 used an inlined version of potemkin import-vars. My initial decision was to create an inlined cljs version of import-vars to match. This was a ton of learning and effort, but it technically worked.

Over time I discovered import-vars does has enough downsides that I ultimately decided to switch to code generation instead. Here are my rewrite-clj v1 notes on import-vars.

So that users can make a more informed choice, I think we should probably mention some of the cons of using import-vars in the readme. I am happy to take a stab at this.

KingMob commented 1 year ago

Sure, want to submit a PR?

lread commented 1 year ago

Thanks, I'll take a stab at it.