(defn sample-component []
[:div
[:p "I am a component!"]
[:p.someclass
"I have" [:strong "bold"] "text."]])
(defn mountit []
(r/render [sample-component]
(.-body js/document)))
(defn init []
(println "Hello world")
(sample-component)
(mountit))
returns
Reagent.core/render function was moved to reagent.dom namespace in Reagent v1.0.
on build
reagent.core/render is deprecated
halpThink I figured it out, was calling reagent.core instead of reagent.dom
Error: Target container is not a DOM element.
Figured out, needed an index.html of the form
<head>
<title>
title
</title>
</head>
<body>
<script src="./js/invoice-frontend.js"></script>
</body>
</html>/** @type {import('tailwindcss').Config} */
module.exports = {
content: ['./src/main/invoice/frontend/*.{cljs}',
'./invoices/invoice-frontend/js/*.{js}',],
theme: {
extend: {},
},
plugins: [],
}
seems to be unable to pull :class tags from in src/main/invoice/frontend/main.cljs. Anyone here using tailwind with cljs?No clue whether these projects are relevant to your particular problem, but at least they're relevant to the question: • https://github.com/jacekschae/shadow-cljs-tailwindcss • https://github.com/teknql/shadow-cljs-tailwind-jit • https://github.com/wilkerlucio/tailwind-garden Somewhat relevant: • https://github.com/green-coder/girouette • https://github.com/mainej/headlessui-reagent
Thanks, was able to get it working by comparing my config to shadow-cljs-tailwindcss repo