-
-
Save eeue56/b1799407ea135bb8a533 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import Json.Encode exposing (string) | |
import VirtualDom exposing (Node, property) | |
import Html exposing (div, Html) | |
style : String -> Html | |
style text = | |
VirtualDom.node | |
"style" | |
[ property "textContent" <| string text | |
, property "type" <| string "text/css" ] | |
[] | |
styleTag : Html | |
styleTag = style "body {background-color: red}" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment