opvasger/develm/4.0.1

NOTE: the latest version is 6.0.1

Unavailable. Nobody can download this version any more, with elm or with the Lamdera compiler: github.com/opvasger/develm is gone (deleted or private); Software Heritage not asked yet (this run's --swh-calls were used up); no fork with the same repo name found; no cached copy. Use another version.

Details

DevElm

| Build BuildConfiguration
| Serve ServeConfiguration
| Batch (List Configuration)
| Sequence (List Configuration)
| OneOf (List ( String, Configuration ))

Configuration for the develm program.

  • Batch performs tasks unordered.
  • Sequence performs tasks sequentially.
  • OneOf performs tasks optionally - OneOf [("build", Build defaultBuild)] is performed with develm build.
= Text String
| Version

Log text messages to the console.

type alias BuildConfiguration =
{ moduleName : String
, outputPath : Maybe String
, format : Format
, mode : Mode
}

Configure DevElm to build an elm program.

type Format
= ImmediatelyInvokedFunctionInvocation
| EcmaScriptModule

Configure what format the program should be built to.

  • EcmaScriptModule allows for native JavaScript-module imports.
  • ImmediatelyInvokedFunctionInvocation exposes the Elm global along with a Node-compatible module.
type Mode
= Develop
| Debug
| Optimize

Configure what mode the program should be built in.

  • Develop is a development-build.
  • Debug is a development-build that includes the time-travelling debugger.
  • Optimize is a production-build that includes minification.
defaultBuild : BuildConfiguration

The default-configuration for building Elm programs. It makes an unoptimized build of a module named Main into build/main.js

type alias ServeConfiguration =
{ moduleName : String
, hostname : String
, port_ : Int
, mode : Mode
, outputPath : String
, documentPath : Maybe String
, contentTypes : Dict String String
, headers : Dict String String
}

Configure DevElm to build an elm program.

defaultServe : ServeConfiguration

The default-configuration for serving Elm programs. It assumes no HTML-document is present.

Internals

These definitions are for program-authors who want to consume the configuration for their own programs.

Encode a configuration as JSON.