This repository was archived by the owner on Oct 7, 2021. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 14
The Examples
Scott Smith edited this page Sep 8, 2018
·
13 revisions
This page covers knowledge conveyed in these two examples and how to set up your system to build and run them.
- How to use Elm flags to retrieve an initial time from Javacript.
- The differences working with utc-only and time zones.
| Name | Version | Installation |
|---|---|---|
| elm | >= 0.18.0 | Install |
| node | v8.9.3 | node dist |
| npm | 5.5.1 | Included as part of node install above |
| elm-live | >= v2.7.5 | npm install -g elm-live |
-
cdinto your Elm projects' folder - Perform the following commands:
git clone git@github.com:elm-community/elm-time.git cd elm-time elm-make --warn cd examples/with-timezone # or examples/without-timezone
- For elm18 installations:
elm-live --output=index.js Main.elm --open --warn
- For elm19 installations:
elm-live Main.elm --open -- --output=index.js
- Browse http://localhost:8000 and observe the following browser screen for with-timezone example:

Change to a different timezone in the dropdown and observe how the ISO8601 rendering changes. - Browse http://localhost:8000 and observe the following browser screen for without-timezone example: