3.0.6 • Published 3 years ago
@sakai-ui/sui-element v3.0.6
sui-element
A base class for Sakai UI elements. It renders to the light dom and gives us the loadTranslations and tr methods.
Installation
npm i @sakai-ui/sui-elementUsage
import { SuiElement } from "@sakai-ui/sui-element";
class MyElement extends SuiElement {
constructor() {
super();
this.loadTransations("myelement").then(r => { this.i18n = r; this.requestUpdate(); });
}
...
}Linting and formatting
To scan the project for linting and formatting errors, run
npm run lintTo automatically fix linting and formatting errors, run
npm run formatTesting with Web Test Runner
To execute a single test run:
npm run testTo run the tests in interactive watch mode run:
npm run test:watch