tricycle/elm-embed-youtube/1.0.1

NOTE: the latest version is 1.1.3

Renamed to bellroy/elm-embed-youtube. It is published under that name, and new versions come out there.

Versions published as tricycle/elm-embed-youtube still install under that name. 3 versions of 6 come from the new location (see their notes). 3 versions could not be recovered and cannot be installed.

Unavailable. Nobody can download this version any more, with elm or with the Lamdera compiler: github.com/bellroy/elm-embed-youtube exists but has no tag 1.0.1; Software Heritage not asked yet (this run's --swh-calls were used up); no fork with tag 1.0.1 found (2 same-name repos checked); no cached copy. Use another version.

Details

Embed.Youtube

Create an embedded Youtube video using the Iframe Player Api

Youtube

type alias Youtube =
Youtube

The type of an Youtube image

type alias Attribute =
Attribute

The type of a Youtube Attribute

Creation

fromUrl : Url -> Maybe Youtube

Attempt to create a new Youtube from an (Youtube) Url containing the v= param.

https://www.youtube.com/watch?v=xLLkZa662Fs
fromString : String -> Youtube

Create a new Youtube from a string representing a VideoId

There is no validation on the input

Attributes

Check Embed.Youtube.Attributes for all the available Attribute helpers

attributes : List Attribute -> Youtube -> Youtube

Add Attributes to your Youtube type

Html

toHtml : Youtube -> Html msg

Renders an iFrame based on your settings