Security News
Weekly Downloads Now Available in npm Package Search Results
Socket's package search now displays weekly downloads for npm packages, helping developers quickly assess popularity and make more informed decisions.
web3-avatar-vue
Advanced tools
Web3 Avatar is a lightweight Vue library for generating beautiful gradient avatars from Ethereum addresses. This is Vue version of the library. If you are looking for other versions like React or vanilla JavaScript, please check the main repository. Inspired by Web3 Modal avatar
See live demo on web3-avatar.netlify.app
You can install the library using npm:
npm install web3-avatar-vue # or yarn add web3-avatar-vue
For more detailed usage instructions see the usage.
<template>
<Web3Avatar address="0x11Ed0AC7D6142481E459B6e5d4bfB5646277796f" />
</template>
<script setup>
import Web3Avatar from 'web3-avatar-vue';
</script>
First, you need to import the style.css
file which contains the styles for the component.
// main.js
import 'web3-avatar-vue/dist/style.css';
Add the style.css
file to the css
array in your Nuxt config file:
/// nuxt.config.js
export default defineNuxtConfig({
... // other config
css: ['web3-avatar-vue/dist/style.css'],
... // other config
})
<!-- index.html -->
<link rel="stylesheet" href="https://unpkg.com/web3-avatar-vue/dist/style.css">
Then, you can import the component:
<script setup>
import Web3Avatar from 'web3-avatar-vue';
</script>
import Web3Avatar from 'web3-avatar-vue';
new Vue({
...
components: {
Web3Avatar
},
...
})
<!-- index.html -->
<script src="https://unpkg.com/web3-avatar-vue"></script>
Finally, you can use the component in your template 🎉:
<Web3Avatar address="0x11Ed0AC7D6142481E459B6e5d4bfB5646277796f" />
Name | Type | Default | Description |
---|---|---|---|
address | String | null | Ethereum address |
npm run test # or yarn test
Released under the MIT License.
FAQs
Vue component for generating beautiful Web3 gradient avatars
The npm package web3-avatar-vue receives a total of 86 weekly downloads. As such, web3-avatar-vue popularity was classified as not popular.
We found that web3-avatar-vue demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
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.
Security News
Socket's package search now displays weekly downloads for npm packages, helping developers quickly assess popularity and make more informed decisions.
Security News
A Stanford study reveals 9.5% of engineers contribute almost nothing, costing tech $90B annually, with remote work fueling the rise of "ghost engineers."
Research
Security News
Socket’s threat research team has detected six malicious npm packages typosquatting popular libraries to insert SSH backdoors.