Skip to content
This repository has been archived by the owner on Apr 16, 2019. It is now read-only.

justinwoo/elm-simple-loader

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Elm Simple Loader

npm

A simple Webpack loader for Elm sources. Uses your system Elm installation.

Usage

Add elm-simple-loader to your loaders:

loaders: [
  {
    loader: 'elm-simple-loader',
    test: /\.elm$/,
    exclude: /node_modules/
  }
]

And then in your JS...

import Elm from '../elm/App.elm';
Elm.fullscreen(Elm.App); and whatnot

Enjoy!

Note

When you bring in precompiled files (like if elm.js contains bits that have been built by elm-make), you'll end up getting warnings about how you're using precompiled files. To shut this error up, you can add this to your module config:

[...]
  module: {
    loaders: [...],
    noParse: [/.elm$/] // tells webpack to not parse Elm sources
  }
[...]

About

deprecated. this package likely does not work anymore.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published