Git Product home page Git Product logo

gacallea / elm_vite_tailwind_template Goto Github PK

View Code? Open in Web Editor NEW
36.0 1.0 2.0 1.36 MB

Opinionated template for building Elm web apps using Vite, TailwindCSS and daisyUI.

Home Page: https://elm-vite-tailwind-template.netlify.app/

License: GNU General Public License v3.0

HTML 11.72% Elm 75.04% CSS 0.55% JavaScript 12.69%
elm elm-lang tailwindcss vite vitejs front-end frontend tailwind webdev webapp web-app web-application web-dev web-development webdevelopment daisyui

elm_vite_tailwind_template's Introduction

Vite, Elm, Tailwind CSS, and daisyUI

Opinionated template for building Elm web applications using Vite, Tailwind CSS, and daisyUI.

Tooling

Vite

Elm

Packages

Shortlist of Elm packages that could be beneficial. Included as suggestions:

To remove them feel free:

  1. not to use them
  2. run npm run review

Tailwind CSS

The official plugins are installed by default:

daisyUI

"The most popular, free and open-source Tailwind CSS component library".

daisyUI: a Tailwind CSS classes component library, aiming to work on all frameworks. The CSS nature of daisyUI makes Elm integration possible and a breeze to use. Examples included:

Node

  • fnm: easily and consistently manage Node.
  • .nvimrc set to use latest lts/iron.

VS Code

Lint/Format

Elm + Tailwind CSS

Get Started

Install tiged

To clone this repository, devoid of .git, you can either use npx degit or install tiged locally and run degit without npx. YMMV.

Tiged is a fork that addresses a number of issues, and should be preferred. To install it, run:

npm uninstall -g degit
npm install -g tiged

Most likely, npx degit would invoke degit. A locally installed binary makes sure you are running tiged instead.

Peruse the template

  1. Clone the template:
    1. using npx: npx degit gacallea/elm_vite_tailwind_template my-elm-app
    2. local binary: degit gacallea/elm_vite_tailwind_template my-elm-app
  2. Enter the project: cd my-elm-app
  3. Install dependencies: npm install
  4. Start developing: npm run dev

Available Commands

script action
postinstall elm-tooling install
dev vite
prebuild elm-tooling install
build vite build
preview npm run build; vite preview
standard standard --fix src/*/.js
markdown standard-markdown --fix src/*/.md
review elm-review --fix-all
test elm-test-rs

Contributing

Contributions and constructive criticism are welcome. If you think I'm overdoing it, feel free to discuss. I'm still experimenting with this, as a learning opportunity, and I strive to improve the template as much as possible.

pre-commit hooks (WIP)

This repo relies on pre-commit-ci to make sure all suggested coding standards are enforced with git hooks. You could also install pre-commit locally to apply the same configuration locally.

Acknowledgements

This templated was inspired by Lindsay K Wardell's template.

elm_vite_tailwind_template's People

Contributors

gacallea avatar pre-commit-ci[bot] avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

elm_vite_tailwind_template's Issues

Include all Elm files recursively

I think this line should be ./src/elm/**/*.elm. It took me a lot of time to find this out :). I was almost quitting the idea of using this template.
Now it works perfectly. Thank you for doing this! ❤️

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.