opvasger/develm/6.0.0

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

type Flags
= Batch (List Flags)
| Sequence (List Flags)
| OneOf (List ( String, Flags ))
| Log LogFlags
| Build BuildFlags
| Serve ServeFlags
| Test TestFlags
| Benchmark BenchmarkFlags

Flags 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 to the console.

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

Flag DevElm to build an elm program.

type Format
= ImmediatelyInvokedFunctionInvocation
| EcmaScriptModule

Flag 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

Flag 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 : BuildFlags

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

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

Flag DevElm to serve an elm program over HTTP.

defaultServe : ServeFlags

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

type alias TestFlags =
{ seed : Maybe Int
, fuzz : Int
, moduleName : String
, testName : String
}

Flag DevElm to test Elm functions.

defaultTest : TestFlags

The default-flags for testing Elm functions.

type alias BenchmarkFlags =
{ moduleName : String
, benchmarkName : String
}

Flag DevElm to benchmark Elm functions.

defaultBenchmark : BenchmarkFlags

The default-flags for benchmarking Elm functions.

Internals

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

encodeFlags : Flags -> Value

Encode flags as JSON.