• Stars
    star
    862
  • Rank 52,908 (Top 2 %)
  • Language
    JavaScript
  • Created almost 9 years ago
  • Updated almost 3 years ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

Boilerplate for developing Elm apps on Webpack

elm-webpack-starter

About:

A simple Webpack setup for writing Elm apps:

  • Dev server with live reloading, HMR
  • Support for CSS/SCSS (with Autoprefixer), image assets
  • Bootstrap 3.3+ (Sass version)
  • Bundling and minification for deployment
  • Basic app scaffold, using Html.beginnerProgram
  • A snippet of example code to get you started!

Install:

Clone this repo into a new project folder, e.g. my-elm-project:

git clone https://github.com/moarwick/elm-webpack-starter my-elm-project
cd my-elm-project

Re-initialize the project folder as your own repo:

rm -rf .git         # on Windows: rmdir .git /s /q
git init
git add .
git commit -m 'first commit'

Install all dependencies using the handy reinstall script:

npm run reinstall

This does a clean (re)install of all npm and elm packages, plus a global elm install.

Serve locally:

npm start
  • Access app at http://localhost:8080/
  • Get coding! The entry point file is src/elm/Main.elm
  • Browser will refresh automatically on any file changes..

Build & bundle for prod:

npm run build
  • Files are saved into the /dist folder
  • To check it, open dist/index.html

Changelog

Ver 0.8.6

  • Update Packages (-> Webpack 2)
  • fix paths in file-loader
  • clean up build script

Ver 0.8.5

  • Fix loading path of generated js file, per Issue 47

Ver 0.8.4

  • Fix hot reloading of components, per Issue 44

Ver 0.8.3

  • Update packages
  • Attempt to fix path issues when building for prod (temp)

Ver 0.8.2

  • Webpack config improvements (PR by Lesuk)

Ver 0.8.0

  • Update to Elm 0.18, use debug=true on webpack loader (PR by douglascorrea)
  • Add a script for one-step installs
  • Update to latest packages

Ver 0.7.1

Ver 0.7.0

  • Modify project structure, per Issue 26
  • Include Bootstrap JS, per Issue 28
  • More helpful install steps in README, per Issue 29
  • Update to latest packages

Ver 0.6.2

  • Use copy-webpack-plugin instead of cp to copy files (Windows compatible)

Ver 0.6.0

  • elm-hot-loader is back (no Elm code changes required!)
  • Switch to bootstrap-sass to demo CSS

Ver 0.5.0

  • Update to Elm 0.17.0 (and other latest modules)
  • Upgrade starter code per upgrade-docs
  • Remove elm-hot-loader (for now)

Ver 0.4.0

Ver 0.3.0

  • Use html-webpack-plugin to generate index.html
  • Apply hash filenames for bundled JS and CSS (prevents caching)
  • Image and favicon assets copied to dist/

More Repositories

1

elm-webpack-loader

Webpack loader for the Elm programming language.
JavaScript
532
star
2

elm-test

moved to elm-explorations/test
Elm
340
star
3

js-integration-examples

Examples of common uses of ports and web components
Elm
138
star
4

list-extra

Convenience functions for working with List.
Elm
135
star
5

webgl

Moved to elm-explorations/webgl
Elm
131
star
6

parser-combinators

A parser combinator library for Elm.
Elm
104
star
7

elm-datepicker

A reusable date picker component in Elm.
Elm
96
star
8

elm-route

A library for parsing routes.
Elm
69
star
9

elm-time

A pure Elm date and time library.
Elm
67
star
10

typed-svg

Typed SVG library written for Elm
Elm
60
star
11

maybe-extra

Convenience functions for working with Maybe.
Elm
51
star
12

json-extra

Convenience functions for working with Json.
Elm
37
star
13

string-extra

String helper functions for Elm.
Elm
34
star
14

elm-compiler-docs

Repo where to write down documentation and guides for the elm-compiler
Ruby
33
star
15

guidelines

guidelines for *-extra contributors
33
star
16

html-extra

Additional functions for working with Html.
Elm
31
star
17

random-extra

Extra functions for the core Random library.
Elm
28
star
18

elm-list-extra

DEPRECATED; use elm-community/list-extra
Elm
17
star
19

html-test-runner

DEPRECATED - Run elm-test suites in the browser
Elm
16
star
20

basics-extra

Additional basic functions for Elm.
Elm
15
star
21

material-icons

Material Icons in Elm.
Elm
14
star
22

linear-algebra

Fast Linear Algebra for Elm.
JavaScript
14
star
23

result-extra

Convenience functions for working with Result.
Elm
13
star
24

dict-extra

A library with extra functions for the dictionary type in elm core.
Elm
13
star
25

elm-json-extra

DEPRECATED. Moved to elm-community/json-extra =>
Elm
10
star
26

array-extra

convenience functions for working with Array
Elm
9
star
27

slack

A meta repo for all things Slack-related
9
star
28

lazy-list

Lazy list implementation in Elm.
Elm
8
star
29

discussions

A repo for holding Elm community discussion rules and metadata
7
star
30

list-split

Split lists into chunks.
Elm
5
star
31

elm-lazy-list

Elm
4
star
32

Elm.tmLanguage

Python
2
star
33

code-confusion-catalog

Community-written documents exploring proposed language additions.
1
star
34

travis-ci

1
star