Welcome

Welcome to the code-example library documentation.

Note: Documentation for the code-example custom element has not been completed.

The <code-example> custom element renders code in a syntax-highlight text block and, if possible, the results of that code in a display frame.

The element is intended for use in documentation, tutorials, demos, or any other place where an example of code would be helpful.

To use the <code-example> custom element, add it to a page with at least one <code> element in its children.

Assign the code element a slot attribute to activate it as example code. Assign a class of language-js, language-html, or language-css to apply syntax highlighting for the respective language.

Use the Documents menu to navigate to a specific feature's documentation.

Documentation for other versions can be found in the Versions dropdown.

Documentation Versioning

Documentation's versioning reflects the latest released build version at the time the documentation was published. It may not reflect the latest version of the library, but all documents should still apply to it.

Please report any discrepencies between the documentation and the latest version to the library's maintainer.