arian / esbuild-plugin-elm

An esbuild plugin for building elm projects

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

esbuild-plugin-elm

An esbuild plugin for building elm projects

npm

Install

Add this plugin to your project's dev-dependencies by running the following -

yarn add -D esbuild-plugin-elm
// OR
npm install -D esbuild-plugin-elm

Usage

A simple example can be found in ./example.

esbuild.build({
  entryPoints: ['src/index.js'],
  bundle: true,
  outfile: 'dist/bundle.js',
  plugins: [
    ElmPlugin(options) // options are documented below
  ],
}).catch(e => (console.error(e), process.exit(1)))

Options

  • debug (optional) Enable the time-travelling debugger

  • optimize (optional) Optimize the js output (true by default if NODE_ENV is production)

  • pathToElm (optional) Specifiy an explicit path to the elm executable

About

An esbuild plugin for building elm projects

License:MIT License


Languages

Language:JavaScript 62.6%Language:Elm 23.3%Language:Nix 10.0%Language:HTML 4.1%