Create your own MapStore2 project

To create a new MapStore2 based project you can use the createProject script:

node ./createProject.js <projectType> <projectName> <projectVersion> <projectDescription> <gitRepositoryUrl> <outputFolder>

All the arguments are mandatory:

At the end of the script execution, the given outputFolder will be populated by all the configuration files needed to start working on the project. Moreover, the local git repo will be initialized and the MapStore2 submodule added and downloaded.

If you create a standard project, you can customize it editing js/app.jsx: look at the comments for hints and the MapStore2 documentation for more details.

If you create a custom project, you will find a simple application in the js folder (app.jsx is the entry point) with two pages (home and main).

The following steps are:

Create a new project type

If you are not happy with the available project types (standard and custom), you can extend them adding a new folder in project.

The folder will contain two subfolders:

In addition to static and templates, the following files from the root MapStore2 folder will be copied: