Component library
Getting started with components
Last updated 2 November 2026
Load the Insites web components on a page and use your first one.
The Insites components are web components: custom HTML tags that work in any page without a build step. Load them once in a layout, then use them on every page.
Insites is frontend-agnostic: you can use any frontend framework and any component library you like. These components are a set Insites has built, and you are welcome to use them.
Load the components on a page
Add these four lines to the <head> of your layout. They load the component styles, the icon font and the components themselves.
app/views/layouts/application.liquid
<link rel='stylesheet' href='https://components.insites.io/v2/latest/css/insites.css'>
<link rel='stylesheet' href='https://components.insites.io/v2/latest/css/insites-font-icons.css'>
<script type='module' src='https://components.insites.io/v2/latest/insites.esm.js'></script>
<script nomodule src='https://components.insites.io/v2/latest/insites.js'></script>The first script loads in modern browsers. The second one loads only in old browsers that cannot run modules. Put the lines in the <head> so the browser knows the tags before it draws the page.
Use a component
Write the tag and set its attributes. This button shows a label, a color and an icon:
<ins-button label='Save changes' color='blue' icon='icon-check-2' solid></ins-button>Attribute names use dashes. For example, the iconRight property is written as icon-right. When someone clicks the button, it sends an insClick event that a developer can listen for.
Find a component
The component library groups every component by what you use it for: actions, form fields, structure, data and feedback. Each page has a live demo, every attribute and every event.
Versions
The v2/latest path always loads the newest release of the website line. To pin one release, or to load only the styles you need, see Versions. Version 1 is retired. If a page still uses it, Migrating from v1 to v2 lists the tags and events that changed.
Warning
The website line takes security fixes only. Do not expect new components or attributes to appear in it.