Set Up
Register the custom element
You can register the custom element using the define function from the @web-cube/web-cube package.
import { define } from "@web-cube/web-cube";define();Using a custom tag name
You can use a custom tag name to define the custom element.
By default, the custom element is defined with the tag name web-cube.
import { define } from "@web-cube/web-cube";define("custom-cube");Embed in your page
Once the custom element is defined, you can easily embed Web Cube in your existing project or start a new project using the following code.
<web-cube></web-cube>Also is possible to you must add some styles to the custom element to adjust the size and position.
web-cube { display: block; width: 100%; height: 100%;}The cube will automatically adjust to the size of container.