<!– markdownlint-disable first-line-heading –>
Kelpie
Documentation for Kelpie.
Kelpie.html
— Methodhtml(content)
Creates a new HTML document filled with content
.
Kelpie.html_element
— Functionhtml_element(name, content=nothing; kwargs...)
Creates a new EzXML.Node
with name name
, containing content
, and with attributes specified by kwargs
.
Example
julia> import EzXML: prettyprint
+Home · Kelpie.jl <!– markdownlint-disable first-line-heading –>
Kelpie
Documentation for Kelpie.
Kelpie.html
— Methodhtml(content...)
Creates a new HTML document filled with content
.
sourceKelpie.html_element
— Methodhtml_element(name, content...=nothing; kwargs...)
Creates a new EzXML.Node
with name name
, containing content
, and with attributes specified by kwargs
.
Example
julia> import EzXML: prettyprint
julia> prettyprint(html_element("img"; src="https://millironx.com/images/charolette.jpg"))
<img src="https://millironx.com/images/charolette.jpg"/>
julia> prettyprint(html_element("span", "MillironX"; class="label-primary"))
-<span class="label-primary">MillironX</span>
sourceKelpie.link_or_text!
— Methodlink_or_text!(node, content)
Converts content
to an EzXML.TextNode
if it isn't already an EzXML.Node
and links it to node
. Will link all nodes in content
if content is a vector.
julia> import EzXML: ElementNode, prettyprint; import Kelpie: link_or_text!
+<span class="label-primary">MillironX</span>
sourceKelpie.link_or_text!
— Methodlink_or_text!(node, content...)
Converts each content
to an EzXML.TextNode
if it isn't already an EzXML.Node
and links it to node
.
julia> import EzXML: ElementNode, prettyprint; import Kelpie: link_or_text!
julia> prettyprint(link_or_text!(ElementNode("div"), ElementNode("br")))
<div>
@@ -15,5 +15,5 @@ julia> prettyprint(link_or_text!(ElementNode("div"), ElementNode(&q
julia> prettyprint(link_or_text!(ElementNode("h1"), "Kelpie.jl"))
<h1>Kelpie.jl</h1>
-julia> prettyprint(link_or_text!(ElementNode("div"), ["The end", ElementNode("hr")]))
-<div>The end<hr/></div>
sourceSettings
This document was generated with Documenter.jl version 0.27.15 on Monday 4 April 2022. Using Julia version 1.7.2.
+julia> prettyprint(link_or_text!(ElementNode("div"), "The end", ElementNode("hr")))
+<div>The end<hr/></div>