Installation

To bootstrap a project with GreenLight, all you have to do is include the following script tag:

<script src="https://www.unpkg.com/@gabrielp03/greenlight/dist/main.js"></script>

NOTE: The link above will always get the latest version. Currently, this project is in beta and can have breaking changes in the future.

You can always specify the version you want:

<script src="https://www.unpkg.com/@gabrielp03/[email protected]/dist/main.js"></script>

After including it, you will have access to it's object attached to the window.

To initiate it, define a root for your project and use the init method.

const AppRoot = document.getElementById("app-root");

GreenLight.init(AppRoot);

This is all you need to start a new project with GreenLight or to add it to an existing project - it doesn't interfere with another library.

Table Content