Libraries
Last updated
Was this helpful?
Last updated
Was this helpful?
The as well as all and related files are normally retrieved from the NPM registry and stored in the node_modules
folder off the root of the theme project.
Component libraries, TypeScript definition files, and other related files specific to a theme are located off the root of a theme project in the \libs
directory.
To be sure all WireBootstrap Typescript declaration files can be found by a project's compiler, the path to the@wirebootstrap
scope root directory is registered in the compilerOptions.typeRoots
attribute inside the project's tsconfig.json
file.
When a custom typeRoots
is specified, be sure to replace the original default that points to the @types
directory as seen above.
All Web components and services published by WireBootstrap are created off of the global wire
JavaScript object located in the core WireBootstrap library wire.js
. Many create a sub namespace and then adds classes, interfaces, and other structures to support a given component or service. This is similar in design to how all jQuery plugins attach to the root jQuery
object.
In TypeScript, all root types, classes, interfaces, and other structures native to the core WireBootstrap JavaScript API begin with IWire
.
The following example casts a raw JavaScript object into a WireBootstrap data table by referencing the IWireDataTable
interface.
The example below creates a new and binds it to an instance of the Bootstrap Select component.