Socket
Socket
Sign inDemoInstall

jdenticon

Package Overview
Dependencies
3
Maintainers
1
Versions
19
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    jdenticon

Javascript identicon generator


Version published
Weekly downloads
29K
decreased by-13.65%
Maintainers
1
Install size
2.45 MB
Created
Weekly downloads
 

Readme

Source

Jdenticon

JavaScript library for generating highly recognizable identicons using HTML5 canvas or SVG.

Sample identicons

Tests Downloads jsDelivr npm bundle size License MIT

Live demo

https://jdenticon.com

Getting started

Using Jdenticon is simple. Follow the steps below to integrate Jdenticon into your website.

1. Add identicon placeholders

Jdenticon is able to render both raster and vector identicons. Raster icons are rendered slightly faster than vector icons, but vector icons scale better on high resolution screens. Add a canvas to render a raster icon, or an inline svg element to render a vector icon.

<!-- Vector icon -->
<svg width="80" height="80" data-jdenticon-value="icon value"></svg>

<!-- OR -->

<!-- Raster icon -->
<canvas width="80" height="80" data-jdenticon-value="icon value"></canvas>

2. Add reference to Jdenticon

Include the Jdenticon library somewhere on your page. You can either host it yourself or use it right off jsDelivr.

<!-- Using jsDelivr -->
<script src="https://cdn.jsdelivr.net/npm/jdenticon@3.2.0/dist/jdenticon.min.js"
        integrity="sha384-yBhgDqxM50qJV5JPdayci8wCfooqvhFYbIKhv0hTtLvfeeyJMJCscRfFNKIxt43M"
        crossorigin="anonymous">
</script>

<!-- OR -->

<!-- Hosting it yourself -->
<script src="-path-to-/jdenticon.min.js"></script>

That's it!

Other resources

API documentation

For more usage examples and API documentation, please see:

https://jdenticon.com

Other platforms

There are ports or bindings for Jdenticon available for the following platforms:

Hosted Jdenticon

Same icons but generated server-side. Service provided by Aaroh Mankad.

http://identicon-api.herokuapp.com/

License

Jdenticon is available under the MIT license.

Keywords

FAQs

Last updated on 07 Aug 2022

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc