Installation
This section will walk you through the steps required to set up ReqEase in your project. You have multiple installation options to choose from, so pick the one that suits your project best.
Installation Instructions
Using package manager (Module Environment)
If you're working in a module environment, you can use npm to install ReqEase as a package. This method is ideal if you want to manage ReqEase as a dependency in your project.
Install ReqEase
This will download and install ReqEase and its dependencies into your project.
Create a Custom ReqEase calling (optional)
While not mandatory, creating a custom ReqEase calling allows you to set default configurations for ReqEase throughout your entire website. For instance, you can specify global options like the validation source, default constraints, and more.
Usage:
By creating a custom class, you avoid repeating the same configuration for ReqEase in every script. This approach simplifies management and maintenance, especially in larger projects.
Using static script tags
If you prefer not to use npm and want a quick way to include ReqEase in your project, you can use a static script tag. ReqEase can be loaded via CDN or by downloading the script and including it in your project.
CDN
To include ReqEase via CDN, add the following script tag to your HTML file's <head>
section:
Local Download
If you prefer a local copy of ReqEase, download the script from the ReqEase repository and include it in your project:
Visit the ReqEase GitHub repository.
Download the
reqease.js
( orreqease.min.js )
file.Place the downloaded file in your project directory.
Include the script in your HTML file:
Additionally, I'll mention that certain configurations, like registering custom classes, are available exclusively in the module environment. To learn more about these advanced options, refer to the advanced configurations section in this documentation.
This flexible installation approach allows you to choose the best setup based on your project's needs, whether you're looking for extensive customization or a straightforward integration.
Last updated