Skip to content

ferflores/heatm

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

32 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

heatm

npm version

javascript heatmap, wraps heatmap.js for point http posting and remote drawing

preview gif

npm install heatm

Local test at /examples/onMemoryLocalDraw/index.html

In order to test the remote post/get drawing run:

node examples/serverTests/index.js

Then open in your browser the following two files:

  • examples/postPoints/index.html
  • examples/drawFromRemote/index.html

Preview:

preview gif

Client post script example

var hmap = heatm({
  postPointsUrl:'http://localhost:3000/setPoints',
  postPointsBatch: 50,
  maxPointsToPost: 500,
  projectName:'default'
});

hmap.startPostingPoints();

(there are more configurations you can see at src/modules/main.js)

hmap begins posting arrays of points to the server, also a project name is sent along the user screen dimensions. The logic to storage the data is server side responsibility, there is an on memory example at examples/serverTests/index.js.

Client draw from remote example

var hmap = heatm({
  projectName:'default',
  getPointsUrl:'http://localhost:3000/getPoints',
  getPointsBatch: 50
});

hmap.drawHeatMapFromRemote();

About

javascript heatmap

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published