Skip to content

Instantly share code, notes, and snippets.

@zecka
Created June 16, 2026 06:24
Show Gist options
  • Select an option

  • Save zecka/ae8aa65c348b513346215bfe16c5f677 to your computer and use it in GitHub Desktop.

Select an option

Save zecka/ae8aa65c348b513346215bfe16c5f677 to your computer and use it in GitHub Desktop.
tailwind-compile-with-node.js
import { compile } from "tailwindcss";
const run = async () => {
const compiledContent = (
await compile(`
@theme {
--container-md: 700px;
}
.test {
color: red;
@apply flex;
@apply w-md;
}
`, {
loadStylesheet: async (id, base) => {
},
})
).build([])
console.log(compiledContent);
}
run()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment