Skip to content

roboz0r/fable-elmish-lit-tailwind

Repository files navigation

Fable Elmish Lit Tailwind

A template for getting started with F# & Fable for web development.

Prerequisites

Getting Started

These commands will install the JavaScript and .NET dependencies. You only need to run these commands when you first start or when you update your dependencies.

npm install
dotnet tool restore
dotnet paket install

^ note that dotnet tool restore is only needed due to dotnet/sdk#37272

Everyday development

The below command starts the development server in watch mode.

npm run dev
# Note: To stop the dev server press Ctrl+C in the terminal

It starts 3 processes in parallel:

  • Fable, the F# to JavaScript compiler, will watch your F# files and recompile them automatically into the build directory.
  • Tailwind CSS provides a set of utility styles. In development mode, it will watch your code and recompile the CSS files as you add more classes.
  • Vite, JavaScript build tooling and development server. It watches the build directory and reloads the pages when the JavaScript changes.

By default, it will start here.

Building for production

The below command builds and bundles your F# and CSS into minified JavaScript in the dist directory. Any files in the public directory are also copied to dist.

npm run build

Understanding the config files

The following configuration files are used to support this project:

About

A template for getting started with Fable

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published