-
-
Notifications
You must be signed in to change notification settings - Fork 45
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
defn- should not be exported #455
Comments
Thanks for the issue. By design squint exports any non-private var, that is intentional. |
The only drawback is doing But perhaps one should be setting up HMR with Clojurescript macros rather than Vite's default React support. |
I can't change the current behavior because the normal behavior of ClojureScript is that you can access vars from other ClojureScript namespaces without adding But fixing I'm not sure what you mean by HMR with CLJS macros. |
Released in 0.6.89 |
Is your feature request related to a problem? Please describe.
React HMR does not work as reliably when a file exports non-react components. The problem is that Clojure by default exports any non private var, and Squint in particular seems to export any variable (this may be a bug).
Example warning from Vite:
Describe the solution you'd like
Only export vars with metadata
:export
. This would be similar to what shadow-cljs provides for external modules.The text was updated successfully, but these errors were encountered: