Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add section for elm and elm-ui compatibiliy #157

Merged
merged 1 commit into from
Apr 2, 2020
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 19 additions & 0 deletions tutorials/elm-ui/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -573,6 +573,25 @@ This allows us to pinpoint the _single_ `el` in the `row` if we need to.
<br />
<hr />

### Using html from Elm

If for any reasons you can't find a situable `elm-ui` functions
for your use cases, the `Element` module provide the [html](https://package.elm-lang.org/packages/mdgriffith/elm-ui/latest/Element#html)
and [htmlAttribute](https://package.elm-lang.org/packages/mdgriffith/elm-ui/latest/Element#htmlAttribute).

You can for example create your normal element using the [Html](https://package.elm-lang.org/packages/elm/html/latest/) package
and convert it to elm-ui `Element`

```elm
myDiv : Html msg
myDiv =
div [] [text "elm div"]

myElementDiv : Element msg
myElementDiv =
html myDiv
```

# Want _More_?

If you enjoyed learning the basics of `elm-ui`
Expand Down