All standard HTML attributes and tags. Some attributes and tags have the same name, e.g. style. To disambiguate them, attributes have a _ (underscore) suffix.
Attributes
Standard, most non-deprecated attributes from https://developer.mozilla.org/en-US/docs/Web/HTML/Attributes. Where an attribute name conflicts with an OCaml keyword, the name is suffixed with _. Most attributes are constructed by passing in a value of some type.
All string-valued attributes allow formatting (interpolation):
div [id "section-%d" section_id] []
Or plain strings:
p [id "toast"] []
Most boolean attributes are plain values and don't need to be constructed with function calls:
input [required]
However, boolean attributes which may be inherited and toggled on/off in children, are constructed by passing in a value:
div
- [contenteditable true]
- [p [] [txt "Edit me!"]; p [contenteditable false] [txt "Can't edit me!"]]
val autocapitalize :
+HTML (dream-html.Dream_html.HTML)
Module Dream_html.HTML
All standard HTML attributes and tags. Some attributes and tags have the same name, e.g. style. To disambiguate them, attributes have a _ (underscore) suffix.
Attributes
Standard, most non-deprecated attributes from https://developer.mozilla.org/en-US/docs/Web/HTML/Attributes. Where an attribute name conflicts with an OCaml keyword, the name is suffixed with _. Most attributes are constructed by passing in a value of some type.
All string-valued attributes allow formatting (interpolation):
div [id "section-%d" section_id] []
Or plain strings:
p [id "toast"] []
Most boolean attributes are plain values and don't need to be constructed with function calls:
input [required]
However, boolean attributes which may be inherited and toggled on/off in children, are constructed by passing in a value:
div [contenteditable true] [
+ p [] [txt "Edit me!"];
+ p [contenteditable false] [txt "Can't edit me!"];
+]
A tag that will not be rendered in the markup. Useful for containing a bunch of child nodes inside a single node without having to litter the DOM with an actual node. Also may be called 'splicing'.
null
- [ p [] [txt "This paragraph."];
- p [] [txt "And this paragraph."];
- p []
- [txt "Are spliced directly into the document without a containing node."]
- ]
A tag that will not be rendered in the markup. Useful for containing a bunch of child nodes inside a single node without having to litter the DOM with an actual node. Also may be called 'splicing'.
null [
+ p [] [txt "This paragraph."];
+ p [] [txt "And this paragraph."];
+ p [] [txt "Are spliced directly into the document without a containing node."];
+]
Also useful for constructing a completely empty node that is erased when printing:
Live reload script injection and handling. Adapted from Dream.livereload middleware. This version is not a middleware so it's not as plug-and-play as that, but on the other hand it's much simpler to implement because it uses type-safe dream-html nodes rather than parsing and printing raw HTML. See below for the 3-step process to use it.
let () = Dream.run
+Livereload (dream-html.Dream_html.Livereload)
Module Dream_html.Livereload
Live reload script injection and handling. Adapted from Dream.livereload middleware. This version is not a middleware so it's not as plug-and-play as that, but on the other hand it's much simpler to implement because it uses type-safe dream-html nodes rather than parsing and printing raw HTML. See below for the 3-step process to use it.
(3) And run the server with environment variable ENV=dev.
⚠️ If this env var is not set, then livereload is turned off. This means that the route will respond with 404 status and the script will be omitted from the rendered HTML.
+]
(3) And run the server with environment variable LIVERELOAD=1.
⚠️ If this env var is not set, then livereload is turned off. This means that the route will respond with 404 status and the script will be omitted from the rendered HTML.
let hello who =
- let open Dream_html in
- let open HTML in
- html [] [
- body [] [
- h1 [] [txt "Hello, %s!" who];
- ];
- ]
+Dream_html (dream-html.Dream_html)
attr name is a new attribute which does not carry any payload. E.g.
let required = attr "required"
since 0.1.0.
val string_attr : string ->?raw:bool ->_string_attr
string_attr name fmt is a new string-valued attribute which allows formatting i.e. string interpolation of the value. Note, the fmt argument is required due to the value restriction.
Note that the version of this library installed on your device may have outdated documentation strings. To view the latest documentation, please visit the repository page.
Core types
These are the types of the final values which get rendered.
type attr
E.g. id="toast".
type node
Either a tag, a comment, or text data in the markup.
Get whether a node is null (empty) or not. Useful for conditional rendering of UIs when you are passed in a node and you don't know if it's empty or not.
All standard HTML attributes and tags. Some attributes and tags have the same name, e.g. style. To disambiguate them, attributes have a _ (underscore) suffix.
attr name is a new attribute which does not carry any payload. E.g.
let required = attr "required"
since 0.1.0.
val string_attr : string ->?raw:bool ->_string_attr
string_attr name fmt is a new string-valued attribute which allows formatting i.e. string interpolation of the value. Note, the fmt argument is required due to the value restriction.
Get whether a node is null (empty) or not. Useful for conditional rendering of UIs when you are passed in a node and you don't know if it's empty or not.
All standard HTML attributes and tags. Some attributes and tags have the same name, e.g. style. To disambiguate them, attributes have a _ (underscore) suffix.
Live reload script injection and handling. Adapted from Dream.livereload middleware. This version is not a middleware so it's not as plug-and-play as that, but on the other hand it's much simpler to implement because it uses type-safe dream-html nodes rather than parsing and printing raw HTML. See below for the 3-step process to use it.
Live reload script injection and handling. Adapted from Dream.livereload middleware. This version is not a middleware so it's not as plug-and-play as that, but on the other hand it's much simpler to implement because it uses type-safe dream-html nodes rather than parsing and printing raw HTML. See below for the 3-step process to use it.
+
+
+
+
+
\ No newline at end of file
diff --git a/odoc.support/odoc.css b/odoc.support/odoc.css
index c23517b..71148de 100644
--- a/odoc.support/odoc.css
+++ b/odoc.support/odoc.css
@@ -1,7 +1,7 @@
@charset "UTF-8";
/* Copyright (c) 2016 The odoc contributors. All rights reserved.
Distributed under the ISC license, see terms at the end of the file.
- odoc 2.4.1 */
+ odoc 2.4.2 */
/* Fonts */
/* noticia-text-regular - latin */
diff --git a/pure-html/Pure_html/Aria/index.html b/pure-html/Pure_html/Aria/index.html
new file mode 100644
index 0000000..54ebf1c
--- /dev/null
+++ b/pure-html/Pure_html/Aria/index.html
@@ -0,0 +1,2 @@
+
+Aria (pure-html.Pure_html.Aria)
All standard HTML attributes and tags. Some attributes and tags have the same name, e.g. style. To disambiguate them, attributes have a _ (underscore) suffix.
Attributes
Standard, most non-deprecated attributes from https://developer.mozilla.org/en-US/docs/Web/HTML/Attributes. Where an attribute name conflicts with an OCaml keyword, the name is suffixed with _. Most attributes are constructed by passing in a value of some type.
All string-valued attributes allow formatting (interpolation):
div [id "section-%d" section_id] []
Or plain strings:
p [id "toast"] []
Most boolean attributes are plain values and don't need to be constructed with function calls:
input [required]
However, boolean attributes which may be inherited and toggled on/off in children, are constructed by passing in a value:
div [contenteditable true] [
+ p [] [txt "Edit me!"];
+ p [contenteditable false] [txt "Can't edit me!"];
+]
A tag that will not be rendered in the markup. Useful for containing a bunch of child nodes inside a single node without having to litter the DOM with an actual node. Also may be called 'splicing'.
null [
+ p [] [txt "This paragraph."];
+ p [] [txt "And this paragraph."];
+ p [] [txt "Are spliced directly into the document without a containing node."];
+]
Also useful for constructing a completely empty node that is erased when printing:
attr name is a new attribute which does not carry any payload. E.g.
let required = attr "required"
since 0.1.0.
val string_attr : string ->?raw:bool ->_string_attr
string_attr name fmt is a new string-valued attribute which allows formatting i.e. string interpolation of the value. Note, the fmt argument is required due to the value restriction.
Get whether a node is null (empty) or not. Useful for conditional rendering of UIs when you are passed in a node and you don't know if it's empty or not.
All standard HTML attributes and tags. Some attributes and tags have the same name, e.g. style. To disambiguate them, attributes have a _ (underscore) suffix.