localhost/:1 Uncaught SyntaxError: The requested module '/node_modules/.vite/deps/cherry-cljs_core__js.js?v=c26eb8e5' does not provide an export named 'str'
I am trying to run the vite example and str is not defined somewherehey. you can see str in action here:
https://dev.livecodes.io/?template=clojurescript
also it works here:
https://squint-cljs.github.io/cherry/
try (prn (str "foo" "bar"))
now my mind is racing of where I can use that confetti
I'll try the vite example later today. were you running it as is, or are you running it with a change?
as-is
// node_modules/cherry-cljs/core.js
function assoc_BANG_(m, k, v, ...kvs) {
m[k] = v;
if (kvs.length != 0) {
return assoc_BANG_(m, ...kvs);
} else
return m;
}
function dissoc_BANG_(m, k) {
delete m[k];
return m;
}
function keyword(s) {
return s;
}
function prn(...args) {
console.log(...args);
}
function nth(coll, idx) {
return coll[idx];
}
export {
assoc_BANG_,
dissoc_BANG_,
keyword,
nth,
prn
};
//# sourceMappingURL=cherry-cljs_core__js.js.map
vite/node_modules/.vite/deps/cherry-cljs_core__js.jsthere is no str there like the error says
are you running cherry locally or from npm? please provide more details :)
if you are running the project locally, you might need to put it in compile mode, with bb dev first
I thought I did what the readme said, npm i and bb dev in the vite dir
btw, this looks very wrong, the implementation above looks like squint
I'm not able to look into it now, perhaps later today
one thing to note is that the cherry version if very much out of date in that package.json
so upgrading it might help
no rush. That sounds promising
fixed 🙂
cool PR welcome :)