Get tailwind compilation working. Create a Makefile. Add a dev check but it doesn't work
This commit is contained in:
parent
ad2401b6ce
commit
48c77c745b
2
.gitignore
vendored
2
.gitignore
vendored
@ -3,3 +3,5 @@
|
||||
build/*
|
||||
/.tab-id
|
||||
\*Claude*
|
||||
/resources/static/output.css
|
||||
/node_modules/
|
||||
|
11
Makefile
Normal file
11
Makefile
Normal file
@ -0,0 +1,11 @@
|
||||
.PHONY: tailwind build publish
|
||||
|
||||
tailwind:
|
||||
npx @tailwindcss/cli -i ./resources/input.css -o ./resources/static/output.css
|
||||
|
||||
build: tailwind
|
||||
rsync -av --delete resources/static/ build/static/
|
||||
clj -M:build
|
||||
|
||||
publish: build
|
||||
rsync -av --delete build/ joe-vps:/home/josephferano/websites/ferano.io/
|
1
deps.edn
1
deps.edn
@ -3,4 +3,5 @@
|
||||
:aliases {:build {:main-opts ["-m" "ferano-io.core"]}
|
||||
:dev {:extra-deps {nrepl/nrepl {:mvn/version "1.0.0"}
|
||||
cider/cider-nrepl {:mvn/version "0.28.5"}}
|
||||
:jvm-opts ["-Ddev=true"]
|
||||
:main-opts ["-e" "(require 'ferano-io.core) (in-ns 'ferano-io.core)" "-r"]}}}
|
||||
|
1079
package-lock.json
generated
Normal file
1079
package-lock.json
generated
Normal file
File diff suppressed because it is too large
Load Diff
16
package.json
Normal file
16
package.json
Normal file
@ -0,0 +1,16 @@
|
||||
{
|
||||
"name": "ferano.io",
|
||||
"version": "1.0.0",
|
||||
"description": "",
|
||||
"main": "tailwind.config.js",
|
||||
"scripts": {
|
||||
"test": "echo \"Error: no test specified\" && exit 1"
|
||||
},
|
||||
"keywords": [],
|
||||
"author": "",
|
||||
"license": "ISC",
|
||||
"dependencies": {
|
||||
"@tailwindcss/cli": "^4.1.10",
|
||||
"tailwindcss": "^4.1.10"
|
||||
}
|
||||
}
|
1
resources/input.css
Normal file
1
resources/input.css
Normal file
@ -0,0 +1 @@
|
||||
@import "tailwindcss";
|
@ -107,7 +107,10 @@
|
||||
[:meta {:charset "utf-8"}]
|
||||
[:meta {:name "viewport" :content "width=device-width, initial-scale=1"}]
|
||||
[:title "Joseph Ferano"]
|
||||
[:script {:src "https://cdn.jsdelivr.net/npm/@tailwindcss/browser@4"}]
|
||||
;; TOOD: This isn't going to work because we removed the http server when running dev
|
||||
(if (System/getProperty "dev")
|
||||
[:script {:src "https://cdn.jsdelivr.net/npm/@tailwindcss/browser@4"}]
|
||||
[:link {:rel "stylesheet" :href "/static/output.css"}])
|
||||
[:style ".menu-toggle:checked + label + .mobile-menu { opacity: 1; visibility: visible; transform: translateY(0); } .menu-toggle { display: none; } .mobile-menu { opacity: 0; visibility: hidden; transform: translateY(-10px); transition: opacity 0.2s ease, visibility 0.2s ease, transform 0.2s ease; } .mobile-menu a { display: block; }"]]
|
||||
[:body
|
||||
[:div {:class "min-h-screen bg-gray-50"}
|
||||
|
8
tailwind.config.js
Normal file
8
tailwind.config.js
Normal file
@ -0,0 +1,8 @@
|
||||
/** @type {import('tailwindcss').Config} */
|
||||
module.exports = {
|
||||
content: ["./src/**/*.clj",]
|
||||
theme: {
|
||||
extend: {},
|
||||
},
|
||||
plugins: [],
|
||||
}
|
Loading…
x
Reference in New Issue
Block a user