Fork me on GitHub
#squint
<
2023-11-17
>
Chris McCormick05:11:17

After reading your post about porting clojure-mode I took a look at porting https://github.com/chr15m/tiny-web-game-engine/ to squint, but the obvious problem is promesa.core. Is there any way I can get around relying on it so heavily other than doing what you did with js-interop and shimming all around it?

Chris McCormick06:11:48

At the moment I am doing very silly things with cljs in order to keep the artifact size small in kb so squint would be much better as I could write less convoluted code and get the same small artifact.

Chris McCormick06:11:53

This is awesome thanks so much. I should have realized the only promesa call I'm using is so trivially replaced ha ha. I'm getting a few clj-kondo lint errors. Is this due to it being a cljc file now? • namespace hyperscript is required by never used. • Unresolved namespae js. • Unresolved symbol: js-delete. • Unresolved symbol "h" (referring to the hyperscript require which it hasn't picked up). After your squint equality change could I replace this with a simple equals instead of using JS coercive~=? (coercive-= (.indexOf (j/lit [:x :y :w :h]) t) -1)

Chris McCormick06:11:19

Have pushed this to a branch called squint-vite . 🙏

borkdude08:11:46

I’m getting no lint warnings. What is your clj-kondo version?

borkdude09:11:24

Moreover, I added a .clj-kondo/config.edn that should take care that no lint warnings appear at all anymore :)

borkdude09:11:34

About coercive-= I don't know why you were using that at all to be honest. What happens if you just write = in CLJS?

Chris McCormick07:11:17

In regular cljs using = balloons the size of the build from 9kb to ~100kb because it has to pull in all the cljs data typing machinery I guess.

borkdude07:11:39

Gotcha, yeah, in squint this isn’t a problem since it has nothing special for equality

👍 1