ansergeyg / sangrid

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Simple grid data structure to play with.

Declare the script library:

<script src="dist/sangrid.js"></script>

Put a canvas on a page:

<canvas id="tutorial" width="850" height="850"></canvas>

Use options to configure the grid.

    <script>
        let config = {
            'canvasId': 'tutorial',
            'width': 100,
            'height': 200,
            'cellCount': 30,
            'cellSize': 20,
            'sepDist':1,
        };
        sangrid.init(config);
    </script>

About

License:GNU General Public License v3.0


Languages

Language:JavaScript 87.8%Language:HTML 11.5%Language:CSS 0.6%