User charts using html5 canvas. The project is written in object-oriented style. To build using a web package. You can run a local server on NodeJS
or use a project without an assembly, including the necessary scripts on the page.
The project supports the expansion of the functional themes. In order to add a theme, you need to create and connect a .js
file, where the instructions for Range.prototype.themes will be located. You can see an example in the folder ./javascript/theme.dark.js
To create a range, you need to create an object of type Range and pass the canvas id to it for initialization. Then you can pass the address for data collection to the setFromUrl
method or transfer the data to the setFromData
method
NPM commands:
npm run build
| yarn build
npm run start
| yarn start
Сlass descriptions:
DataSet
- class for working with input data for a chart;EventEmmiter
- class for convenient work with user events;MinMap
- class for working with a small navigation map under the main chart;Range
- main class for work diagrams;RangeHud
- class for displaying navigation bars for a chart;SceneObject
- object canvas scene for more flexible work with event handling.Total size: 31.5 KB