Skip to main content

Installation

What you'll need

  • Node.js version 16.14 or above:
    • When installing Node.js, you are recommended to check all checkboxes related to dependencies.

Installing the package

The easiest way to install @jaspero/web-components is to use the npm command.

You can do this by running the command:

npm i --save-exact @jaspero/web-components

You can type this command into Command Prompt, Powershell, Terminal, or any other integrated terminal of your code editor.



Component dependancies

For components to display properly, you'll need to import default styles and css variables at the top level of your project;

<style>@import '@jaspero/web-components/dist/index.css';</style>

Some components require additional imports to function properly.

Simplest way to do this is to load the following scripts and stylesheets;



Quill

<link href="https://cdn.quilljs.com/1.3.6/quill.snow.css" rel="stylesheet" />
<script src="https://cdn.quilljs.com/1.3.6/quill.js"></script>


Code editor

<link
href="https://cdnjs.cloudflare.com/ajax/libs/codemirror/5.65.14/codemirror.min.css"
rel="stylesheet"
/>
<script src="https://cdnjs.cloudflare.com/ajax/libs/codemirror/5.65.14/codemirror.min.js"></script>


Json editor

<link
href="https://cdnjs.cloudflare.com/ajax/libs/jsoneditor/9.10.2/jsoneditor.min.css"
rel="stylesheet"
type="text/css"
/>
<script src="https://cdnjs.cloudflare.com/ajax/libs/jsoneditor/9.10.2/jsoneditor.min.js"></script>