# hexgrid.js

A javascript library implementing hexagonal grids in various forms.

## Usage
There are currently 3 main ways to directly use `hexagonal-grid`, with a canvas
    
    var grid = new hexgrid.CanvasHexagonalGrid();
    grid.animate();

with webgl

    var grid = new hexgrid.WebGLHexagonalGrid();
    grid.animate();

or directly in the DOM

    var grid = new hexgrid.DOMHexagonalGrid();

## Examples
For a full list of examples, go to the [examples page](https://hitcherland.github.io/hexagonal-grid.js/examples)

## Installation
### Direct Download
Download the javascript file [here](https://hitcherland.github.io/hexagonal-grid.js/hexagonal-grid.js), 
([minified](https://hitcherland.github.io/hexagonal-grid.js/hexagonal-grid.min.js), 
[map](https://hitcherland.github.io/hexagonal-grid.js/hexagonal-grid.min.js.map))

### CDN
Use directly in your HTML page

    <script type="text/javascript" src="https://hitcherland.github.io/hexagonal-grid.js/hexagonal-grid.min.js"></script>

### npm
Install from the npm repositories

    npm i hexagonal-grid

### github
Or pull directly from github

    git clone https://hitcherland.github.io/hexagonal-grid


