Last active
November 15, 2016 02:37
-
-
Save giisyu/8800f79e075995600df73c2619bcd924 to your computer and use it in GitHub Desktop.
Elm内にtwitterボタン等scriptタグがあるものを貼る ref: http://qiita.com/jooex/items/6757a1cf9a57fddb3829
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 Html exposing (..) | |
import Html.Attributes exposing (..) | |
script_ : List (Attribute msg) -> List (Html msg) -> Html msg | |
script_ = | |
Html.node "script" | |
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
socialTwitterButton = | |
div [] | |
[ a | |
[ class "twitter-follow-button" | |
, attribute "data-show-count" "false" | |
, href "https://twitter.com/joo_ex" | |
] | |
[ text "Follow @joo_ex" ] | |
, script_ [] | |
[ text "!function(d,s,id){var js,fjs=d.getElementsByTagName(s)[0],p=/^http:/.test(d.location)?'http':'https';\n if(!d.getElementById(id)){js=d.createElement(s);\n js.id=id;\n js.src=p+'://platform.twitter.com/widgets.js';\n fjs.parentNode.insertBefore(js,fjs);\n }}(document, 'script', 'twitter-wjs');" | |
] | |
] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment