snapsvg-hexagonal
v0.0.2
Published
Snap.svg plugin for creating hexagonal UI elements
Downloads
4
Maintainers
Readme
Snap.svg plugin for creating hexagonal UI elements.
Installation
npm install snapsvg snapsvg-hexagonal
Usage
AMD (Require.js)
Add to paths attrbute of requirejs config file and require in code
// config.js
requirejs.config({
paths: {
snapsvg: 'path/to/node_modules/snapsvg/snapsvg',
hexagonal: 'path/to/node_modules/snapsvg-hexagonal/dist/snapsvg-hexagonal'
}
});
// main.js
define(function(require) {
'use strict';
const Snap = require('snapsvg');
const hexagonal = require('hexagonal');
Snap.plugin(hexagonal);
});
Browser global
<!DOCTYPE html>
<html lang="en">
<head>...</head>
<body>
<script src="path/to/node_modules/snapsvg/snapsvg.js"></script>
<script src="path/to/node_modules/snapsvg-hexagonal/dist/snapsvg-hexagonal.js"></script>
<script type="text/javascript">
Snap.plugin('hexagonal');
/* code code code */
</script>
</body>
</html>
Features
Under construction
Contributing
Please read the contributing guide
Roadmap
- Follow progress on Trello
Credits
- Under construction