GithubHelp home page GithubHelp logo

happy-ferret / gixi Goto Github PK

View Code? Open in Web Editor NEW

This project forked from npmcdn-to-unpkg-bot/gixi

0.0 2.0 0.0 16 KB

HTML5 canvas based GitHub identicons like pixel/avatar images generator library. Available as jquery plugin, commonjs or es6 library or even directly work with it from vanillaJS.

Home Page: http://www.linuxenko.pro/showcase/gixi/jquery-example.html

License: MIT License

JavaScript 100.00%

gixi's Introduction

GIXI

HTML5 canvas based GitHub identicons like pixel/avatar images generator library. Available as jquery plugin, es6 or vanillaJS.

Donate


Using jQuery library demo
VanillaJS demo

CodePen live demo

Installation

Installation via npm

npm install gixi

Installation via bower

bower install gixi

Using CDN

<script src="https://unpkg.com/[email protected]/dist/gixi-min.js"></script>

Or download it from current release gixi-min.js 2.96Kb

Usage

Make identicons using jQuery

  • Download and install gixi-min.js library
  • Use following code to invoke gixification of your dom elements
  $('.avatar-element').gixi();

  // or using custom colors

  var color = "#000";
  $('.avatar-element').gixi(color);

Make identicons without jQuery

  • Download and install gixi-min.js library
  • Use following code to invoke gixification of your dom elements
 /*
  *  Generate gixi image for size of 300
  */

  var imageSize = 300;
  var imageData = new GIXI(imageSize).getImage();

  /*
   *  Then place it to your dom element
   */

  var element = document.getElementById('gixie');

  element.setAttribute('src', imageData);

Browserify, Webpack

var GIXI = require('gixi');

License

MIT

Copyright (c) 2014 Svetlana Linuxenko

gixi's People

Contributors

linuxenko avatar npmcdn-to-unpkg-bot avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.