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

aptos-avatars-react-native

Package Overview
Dependencies
Maintainers
1
Versions
14
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

aptos-avatars-react-native

  • 2.1.2
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
25
decreased by-76.19%
Maintainers
1
Weekly downloads
 
Created
Source

Aptos Avatars

Aptos Avatars React Native

Implementation of the Aptos Avatars shape library for React Native applications.

Installation

pnpm add aptos-avatars-react-native

How to Use

The avatar compoennt can be imported as a React Native component which renders an inline SVG element. If you choose to use a single shape, you can import the shape avatars directly. The package is built with ES Modules so the rest of the package will be tree-shaken out of your bundle.

import { AptosAvatar, Shape2 } from "aptos-avatars-react-native";

// Usage
const App = () => {
  return (
    <div>
      <AptosAvatar value="0xd2cf...cff23" border shadow />
      <Shape2 value="0xd2cf...dff23" />
    </div>
  );
};

export default App;

Props

nametypedefaultdescription
value*stringrequiredUnique identifier for the user (e.g., address or Aptos Name) to randomly generate a shape and color
sizenumber32Size of the icon
shadowbooleanfalseToggle the border
borderbooleanfalseToggle the shadow
borderSizenumber2Width of the border, in pixels
borderColorstring#fffColor of the border
radiusnumbersizeBorder radius of the avatar, in pixels
displayValuestringN/AValue to be displayed on the avatar instead of value. This can be a name instead of an identifier
style"character" | "shape""character"Style of the avatar (either "character" or "shape")

FAQs

Package last updated on 11 Sep 2023

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