diff options
author | Jakub Hampl <kopomir@gmail.com> | 2018-06-19 09:05:14 +0100 |
---|---|---|
committer | Jakub Hampl <kopomir@gmail.com> | 2018-06-19 09:05:14 +0100 |
commit | 5fdcf1fbe9a56951799d89bfc43e286742a2495f (patch) | |
tree | 189ebccd30cba8ff373ee67ff69a2552e534de8f /src/Mapbox/Helpers.elm |
Initial commit
Diffstat (limited to 'src/Mapbox/Helpers.elm')
-rw-r--r-- | src/Mapbox/Helpers.elm | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/src/Mapbox/Helpers.elm b/src/Mapbox/Helpers.elm new file mode 100644 index 0000000..f2072aa --- /dev/null +++ b/src/Mapbox/Helpers.elm @@ -0,0 +1,14 @@ +module Mapbox.Helpers exposing (..) + +import Json.Encode as Encode exposing (Value) +import Mapbox.Expression exposing (Anchor(..)) + + +encodeAnchor : Anchor -> Value +encodeAnchor v = + case v of + Viewport -> + Encode.string "viewport" + + Map -> + Encode.string "map" |