Security News
Research
Data Theft Repackaged: A Case Study in Malicious Wrapper Packages on npm
The Socket Research Team breaks down a malicious wrapper package that uses obfuscation to harvest credentials and exfiltrate sensitive data.
@carbon/icons-vue
Advanced tools
Vue components for icons in digital and software products using the Carbon Design System
Vue components for icons in digital and software products using the Carbon Design System
To install @carbon/icons-vue
in your project, you will need to run the
following command using npm:
npm install -S @carbon/icons-vue
If you prefer Yarn, use the following command instead:
yarn add @carbon/icons-vue
Icons in this package support the following sizes: 16
, 20
, 24
, and 32
pixels. These sizes refer to the width and height of the icon.
You can install these components from @carbon/icons-vue
through two ways. The
first is to install them when you're initializing your Vue app. For example:
import { CarbonIconsVue } from '@carbon/icons-vue';
import Bee32 from '@carbon/icons-vue/es/bee/32';
import Vue from 'vue';
import App from './App.vue';
Vue.use(CarbonIconsVue, {
components: {
Bee32,
},
});
new Vue({
render: h => h(App),
}).$mount('#app');
Note: if you would like to find the import path for an icon, you can reference our icon preview
Using CarbonIconsVue
we can pass in any of the icon components that we'd like
to use. In our application, we can then use them by doing:
<template>
<Bee32 />
</template>
If you would rather not register icons globally, you can also import them into individual components.
import Bee32 from '@carbon/icons-vue/es/bee/32';
export default {
name: 'MyComponent',
component: {
Bee32,
},
};
You can pass in props to any icon component for things like accessibility labels, custom classes, event handlers, and more. For example:
<template>
<Bee32 aria-label="Bee" class="custom-class" v-on:click="handler" />
</template>
If you're looking for more examples on how to use @carbon/icons-vue
, we have
some examples that you can check out:
We're always looking for contributors to help us fix bugs, build new features, or help us improve the project documentation. If you're interested, definitely check out our Contributing Guide! 👀
Licensed under the Apache 2.0 License.
FAQs
Vue components for icons in digital and software products using the Carbon Design System
We found that @carbon/icons-vue demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 0 open source maintainers 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
Research
The Socket Research Team breaks down a malicious wrapper package that uses obfuscation to harvest credentials and exfiltrate sensitive data.
Research
Security News
Attackers used a malicious npm package typosquatting a popular ESLint plugin to steal sensitive data, execute commands, and exploit developer systems.
Security News
The Ultralytics' PyPI Package was compromised four times in one weekend through GitHub Actions cache poisoning and failure to rotate previously compromised API tokens.