clojurescript

ClojureScript, a dialect of Clojure that compiles to JavaScript http://clojurescript.org | Currently at 1.10.879
2021-06-23T14:54:07.499500Z

Hey guys! I'm looking for a recommendation for an M17n/internalisation library for Reagent. I'm mostly interested just in M17n, so just plain old translations, less bothered by full internalisation, date formats and such. Something light and simple preferably 🙏:skin-tone-3:

Martin Mariano 2021-06-27T18:25:38.034800Z

I can't recommend mozilla fluent enough. I am using it in a big project of mine and it has been a breeze. Interop very easily with js. https://github.com/projectfluent/fluent.js/ and https://github.com/projectfluent/fluent.js/tree/master/fluent-react

👍 1
p-himik 2021-06-23T15:03:07.499700Z

I'm pretty happy with https://github.com/ptaoussanis/tempura

👍 1
isak 2021-06-23T15:37:45.000100Z

This isn't a library, but some macros/functions that we use at my work: https://www.isaksky.com/posts/macro-assisted-translations-in-clojurescript/

👍 1
2021-06-23T23:15:04.004800Z

In Clojurescript 1.10.773, I could reliably tell whether a symbol sym (at macro-expansion time) referred to a protocol by examining the following:

(:protocol-symbol (cljs.analyzer.api/resolve &env sym))
When I update to Clojurescript 1.10.866, this doesn't seem to work any longer. As far as I can tell, nothing obvious has changed in the code -- defprotocol still attaches this data, and cljs.core still https://github.com/clojure/clojurescript/blob/ac23fec265bdf0ca971eb35c16da4b59191da5ca/src/main/clojure/cljs/core.cljc#L1421. Is there a better / supported way to do this?

2021-06-24T14:51:38.012900Z

@thheller Thank you!

2021-06-23T23:20:04.005Z

Update: 1.10.844 appears to still return :protocol-symbol.

phronmophobic 2021-06-23T23:21:27.005200Z

Are you clearing the cache before building? It's been a while, but I remember some var information only being available when building from scratch

2021-06-23T23:24:06.005400Z

I'll check that.

2021-06-23T23:31:47.005600Z

Yeah, unless I'm doing something very wrong, that's not the issue here; also, our CI also is failing on 866, and afaik it's building cacheless.

👍 1
phronmophobic 2021-06-23T23:35:01.005900Z

dang

2021-06-23T23:44:00.006100Z

Thanks for the idea!

2021-06-23T23:59:17.006300Z

I've narrowed down the commit that breaks my tool to this one: https://github.com/clojure/clojurescript/commit/a8422ee060d7d98f7578c9acb2824a5e346e7958 I'll try to take time later to read through and understand how.