Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

ethereum-blockies-base64

Package Overview
Dependencies
Maintainers
1
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

ethereum-blockies-base64

A tiny library for generating base64 encoded PNG blocky identicons.

  • 1.0.2
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
14K
decreased by-15.6%
Maintainers
1
Weekly downloads
 
Created
Source

Ethereum Blockies Base64

A tiny library for generating blocky identicons as base64 encoded PNGs.

Sample of generated blockies

See a live demo of it in action

Install

# NPM
npm install --save ethereum-blockies-base64

# Yarn
yarn add ethereum-blockies-base64

Use

Vanilla JS

import makeBlockie from 'ethereum-blockies-base64';

const img = new Image() ;
img.src = makeBlockie('0x7cB57B5A97eAbe94205C07890BE4c1aD31E486A8');

document.body.appendChild(img);

React

import React from 'react';
import makeBlockie from 'ethereum-blockies-base64';

class Blockie extends React.Component {
  render() {
    return <img src={makeBlockie(this.props.address)}/>
  }
}

Note: In a real setting, we recommend saving to state and re-making the blockie on prop change for better re-render performance.

License

MIT

FAQs

Package last updated on 06 Jul 2018

Did you know?

Socket

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
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc