This article tells how to prepare the workspace for developing with Webix and lists all available ways of installing the library:
For the simplest Webix app, you need just an HTML file (HTML5 doctype recommended) with:
The lib package contains two versions of Webix JS file:
All the coding can be done in any text editor (Sublime, Visual Studio Code, etc.), optionally you can enable code completion.
You can directly set links to webix.js and webix.css files located in Webix CDN:
This variant is suitable only for the open-source Webix edition distributed under General Public Licence (GPL).
The Webix library can be installed via dependency management tools like NuGet, a package manager for the Microsoft development platform.
Installing Webix by means of this tool requires executing just a line of code:
nuget install Webix // if you use Microsoft Visual Studio, execute this from Package Manager Console install-package Webix
This variant is suitable only for the open-source Webix edition distributed under General Public Licence.
To install the open-source version, you just need to run the next command:
npm install webix
If you have a Webix PRO, you can install it via NPM.
You need to register a developer in your Webix Clients Area (the Users section). Then you will get credentials for accessing Webix npm repository:
After that you will be able to install Webix PRO and Complex widgets according to your license. Updates will be available during the whole licensing period.
You can get the package locally by:
You can enable suggestions and automatic completion for Webix methods in text editors, e.g. Visual Studio Code.
If you import Webix as ES6 code, the autocompletion will work automatically:
import * as webix from "@xbs/webix-pro"; const t = webix.uid();// will show the signature and types of Webix methods
If you use Webix as global, you can use the following reference instruction (aka triple-slash directive):
/// <reference path="../../node_modules/@xbs/webix-pro/types/webix.global.d.ts" /> const t = webix.uid();// will show the signature and types of Webix methods
The directive will instruct the compiler to include the TypeScript type definitions to enable autocompletion of code.
Note that the reference instruction must be at the beginning of the file or after other reference instructions of comments. If it is preceded by a statement or declaration, it is ignored as any other comment.