diff --git a/examples/todos/app/Effect.elm b/examples/todos/app/Effect.elm index cd19760b..285d3c6b 100644 --- a/examples/todos/app/Effect.elm +++ b/examples/todos/app/Effect.elm @@ -1,4 +1,10 @@ -module Effect exposing (Effect(..), batch, fromCmd, map, none, perform) +module Effect exposing (Effect(..), none, batch, fromCmd, map, perform) + +{-| + +@docs Effect, none, batch, fromCmd, map, perform + +-} import Browser.Navigation import Form.FormData exposing (FormData) @@ -8,6 +14,7 @@ import Pages.Fetcher import Url exposing (Url) +{-| -} type Effect msg = None | Cmd (Cmd msg) @@ -31,21 +38,25 @@ type alias RequestInfo = } +{-| -} none : Effect msg none = None +{-| -} batch : List (Effect msg) -> Effect msg batch = Batch +{-| -} fromCmd : Cmd msg -> Effect msg fromCmd = Cmd +{-| -} map : (a -> b) -> Effect a -> Effect b map fn effect = case effect of @@ -82,6 +93,7 @@ map fn effect = |> SubmitFetcher +{-| -} perform : { fetchRouteData : { data : Maybe FormData diff --git a/examples/todos/app/View.elm b/examples/todos/app/View.elm index 06be9240..26eae214 100644 --- a/examples/todos/app/View.elm +++ b/examples/todos/app/View.elm @@ -1,14 +1,22 @@ module View exposing (View, map, placeholder) +{-| + +@docs View, map, placeholder + +-} + import Html exposing (Html) +{-| -} type alias View msg = { title : String , body : List (Html msg) } +{-| -} map : (msg1 -> msg2) -> View msg1 -> View msg2 map fn doc = { title = doc.title @@ -16,6 +24,7 @@ map fn doc = } +{-| -} placeholder : String -> View msg placeholder moduleName = { title = "Placeholder - " ++ moduleName diff --git a/examples/todos/elm-application.json b/examples/todos/elm-application.json index fdbc58e4..260a5b0e 100644 --- a/examples/todos/elm-application.json +++ b/examples/todos/elm-application.json @@ -1,8 +1,11 @@ { - "name": "dmy/elm-doc-preview", - "summary": "Offline documentation previewer", - "version": "5.0.0", + "name": "user/elm-pages-local", + "summary": "elm-pages local generated module documentation", + "version": "1.0.0", "exposed-modules": [ - "Page" + "RouteBuilder", + "View", + "Effect", + "Route" ] } \ No newline at end of file diff --git a/generator/src/elm-application.json b/generator/src/elm-application.json index 208b5e5c..260a5b0e 100644 --- a/generator/src/elm-application.json +++ b/generator/src/elm-application.json @@ -4,6 +4,8 @@ "version": "1.0.0", "exposed-modules": [ "RouteBuilder", + "View", + "Effect", "Route" ] } \ No newline at end of file