Fork me on GitHub
#squint
<
2023-01-31
>
borkdude13:01:59

❤️ 6
🎉 4
chromalchemy21:01:12

If run squint code from a script tag (eliding import & export declarations), can it use functions from the hosted module directly?… when required in a previous script tag like so:`

[:script {:type "module"} "import squintCljs from ''"]
Does this library need to be attached to window for global access like that?

chromalchemy22:01:58

Or is there an example of how to use standard squint lib with hosed helper lib for automatic imports?

chromalchemy22:01:52

I’m having trouble getting these statements to resolve

import { _PLUS_, apply } from 'squint-cljs/core.js'
(if I’m trying to use a remote squint-js helper lib instance)

borkdude22:01:10

You can use import maps for this like in this HTML: https://squint-cljs.github.io/squint/

chromalchemy23:01:27

Thank you! Will try out that config. Is there a simple way to use squint-cljs/core.js directly without doing the module, shim stuff? Do I need the “interpeter” (eval) part if I am just trying to use cljs standard fns (like apply ) in a basic transpilation way?

borkdude09:02:33

I'm not sure if I understand your question