You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
shadow-cljs does not support foreign libs inside cljs libraries. As per Thomas Heller advice - you should fetch decimal.js from npm separately and create the following namespace to make the npm version available to funcool/decimal
;;file: src/cljs/decimal/extern/decimaljs.cljs adjust according to your code layout
(nsdecimal.extern.decimaljs
(:require ["decimal.js":as decimal-js]))
(js/goog.exportSymbol"Decimal.noConflict" (fn [] decimal-js))
While @achikin's solution works, would it be a good idea to support compilation with shadow out of the box? Shadow is somewhat popular these days and it might be a best practice for a small useful library like this to work with at least the most common cljs build tools without having to add an additional namespace.
Compilation fails while trying to compile the library with shadow-cljs.
The following error is shown.
The text was updated successfully, but these errors were encountered: