Skip to content

Example nano-jsx using WindiCSS and a simple server-side live reload script.

Notifications You must be signed in to change notification settings

drawveloper/deno-nano-jsx-windicss-live-reload

Repository files navigation

Nano JSX with Deno

Deploy with Deno Deploy:

This is the starter I wish I had two weeks ago. The simplest JSX setup you can use for Deno server side rendered apps.

  • Deno with Oak server
  • WindiCSS
  • LiveReload
  • Markdown rendering example

Getting started

Create a .env file to add tokens and enable live reload:

echo "ENABLE_LIVE_RELOAD=true" > .env

npm i

npm start

Current workaround

I originally designed this to use concurrently with deno and windi in dev mode, running in parallel. However, due to windicss/windicss#694 I'm currently calling windicss one-off upon server restart. This ensures CSS is correctly generated and takes only ~300ms.

Note about JSX pragma

/** @jsxImportSource https://esm.sh/[email protected]/lib **/ in every jsx component is unfortunately required to deploy on Deno Deploy — they don't support import maps yet.

About

Example nano-jsx using WindiCSS and a simple server-side live reload script.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published