Fork me on GitHub
Tiago Dall'Oca16:05:43

any examples on how to use I'm getting build hook: my.util/hook failed to load and will not be used


@mrdalloca start a clojure repl and load the namespace. eg. shadow-cljs clj-repl then (require 'my.util). that apparently fails?


I'm assuming here you actually changed the namespace and didn't use my.util?

Tiago Dall'Oca16:05:04

it has to be a .clj file

Tiago Dall'Oca16:05:31

is there any way to interact with the cljs runtime during compilation?


during compilation there is no cljs runtime. the runtime will only load the final result


what do you want to do?

Tiago Dall'Oca17:05:26

a very specific use case haha

Tiago Dall'Oca17:05:22

I want to be able to load malli schemas and spit out a file containing said schemas (simplifying)

Tiago Dall'Oca17:05:43

those schemas are defined in my cljs code


not possible in a hook


you can move the schemas to .cljc files though

Tiago Dall'Oca17:05:17

that's what I thought

Tiago Dall'Oca17:05:28

I'm doing some porting to test this


I just tried it but I’m getting:

shadow.user=> (shadow/release-snapshot :app {})
Syntax error compiling at (REPL:1:1).
No such var: shadow/release-snapshot


that post is super old and build reports are the current thing


aaahhh sorry about that - I did first try searching the user guide for release-snapshot but didn’t see anything. Thanks again for all your hard work on shadow - such a great tool!

👍 1
Tiago Dall'Oca18:05:21

@thheller if I'm using snapshot dependencies, how to download them again?


no clue. I have never used a snapshot dependency 😛


deleting .shadow-cljs/classpath.edn maybe?


don't actually know what makes them update

Tiago Dall'Oca19:05:21

I'm just deleting the dependencies from disk 😛

Tiago Dall'Oca19:05:34

working for now but not ergonomic haha

Tiago Dall'Oca19:05:48

I won't need this specifically often I think

👀 1