Fork me on GitHub
#shadow-cljs
<
2017-11-25
>
sundbp00:11:39

@thheller indeed. i think it had something to do with bad target/ cache + order of REPL and so forth. once i cleaned it out, started again and I had state I could explore and figured out the nested call.

sundbp00:11:57

thanks - i’m really liking shadow-cljs so far, really good experience.

Hendrik Poernama08:11:27

is there any config needed to enable css reloading? I got code reload to work, but css requires page refresh.

thheller08:11:36

@poernahi css reloading currently requires that you use absolute paths

thheller08:11:56

<link rel="stylesheet" href="/css/foo.css"/>

thheller08:11:16

if you use the built-in :devtools {:http-root ...} http server it should just work

thheller08:11:42

if not you need to specify :devtools {:watch-dir ...} which should be the path to your http root folder

thheller08:11:51

:watch-dir "public" will reload public/css/foo.css when it finds the link in HTML

thheller08:11:27

@sundbp if you run into that again please report what you were doing. I hate caching issues and want to fix all of them (in case it is one).

Hendrik Poernama08:11:58

Gotcha. Will try that. Thanks

sundbp10:11:22

@thheller sure, will do. I’ve just recently looked at cljs+node for some CLI tools requiring fast startup time, only done jvm clojure otherwise. So I’m new to shadow-cljs, and node, and npm/yarn so I may well have done steps in an unnatural order resulting in the weird situation. I can’t recall it but if I have to guess it may have been related to adding the dependency via yarn add and not restarting everything. Nothing complained and the shims etc looked sensible, but in the REPL session they weren’t available. So gut feel if I’d just restarted the node dev-output/foo.js at the time it’d have gotten picked up properly as shadow-cljs had done it’s thing. I was expecting the require in the shim to blow up or work as expected though, seemed to have silently errored instead.

thheller10:11:39

installing something with yarn does not require a restart. REPL might have some edge cases related to loading. builds should be fine.