I’ve got a :target :bootstrap
build and it works great to get all the sources, but if any code captured in the bootstrap is changed and then after-load
function is called in the host build and I run boot/init
again, I get stale code in the bootstrap build. Seems if the index has been built once, it never tries to fetch any code again.
Feels a bit at odds with the fantastic reload mechanics of Shadow, and is not particularly helpful while developing. I tried a workaround where I would simply reset the index-ref and force all sources to be fetched again, but the ran into issues with goog
namespaces “already being provided”.
Feels like I’m maybe holding the tool wrong? Has anyone else found a nice reloadable workflow when working with the bootstrap target?
Is there anything I'm missing here? Trying to convert this js example
import {AgGridColumn, AgGridReact} from 'ag-grid-react';
import 'ag-grid-community/dist/styles/ag-grid.css';
import 'ag-grid-community/dist/styles/ag-theme-alpine.css';
to a cljs import.
["ag-grid-react" :as agr :refer [AgGridReact]]
;;TODO: can't figure out how to bring in styles:
["ag-grid-community/dist/styles/ag-grid.css"]
["ag-grid-community/dist/styles/ag-theme-alpine.css"]
The compiler error looks like this:
errors in file: /home/jarrett/.../NewSite/node_modules/ag-grid-community/dist/styles/ag-grid.css
{:js-str-offsets [], :js-esm false, :js-imports [], :js-invalid-requires [], :goog-provides [], :js-language "es8", :goog-module nil, :js-warnings [], :resource-name "node_modules/ag-grid-community/dist/styles/ag-grid.css", :js-requires [], :js-errors [{:line 6, :column 72, :message "Semi-colon expected"}], :goog-requires [], :tag :shadow.build.npm/errors, :uses-global-buffer false, :uses-global-process false}
ExceptionInfo: errors in file: /home/jarrett/.../NewSite/node_modules/ag-grid-community/dist/styles/ag-grid.css
@jatkin CSS is not supported and cannot be imported that way via CLJS :require
Gacha, just importing it via <link ... for now.
How to import use <link? Thanks.
Just via html tags
Hi folks, can I create an npm package with shadow-cljs that I can then import in a typescript project?
you can via :npm-module
Hi, We're noticing that since shadow-cljs 2.10.0 the autocomplete/intellisense is broken, when using VS Code & Calva, is this a known issue? (curiously it does work for a few seconds after jack-in but breaks when the build is compiled)
Please note that this issue also affects cljs completions in Calva if the JSCompletion setting is enabled. Disable this in VS Code for shadow projects until a resolution is found.