Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/beyonk-group/svelte-simple-icons
Simple Brand Icons for Svelte
https://github.com/beyonk-group/svelte-simple-icons
Last synced: 3 months ago
JSON representation
Simple Brand Icons for Svelte
- Host: GitHub
- URL: https://github.com/beyonk-group/svelte-simple-icons
- Owner: beyonk-group
- License: mit
- Created: 2019-10-30T09:04:11.000Z (about 5 years ago)
- Default Branch: master
- Last Pushed: 2022-07-20T16:49:56.000Z (over 2 years ago)
- Last Synced: 2024-07-04T22:35:54.800Z (4 months ago)
- Language: JavaScript
- Size: 26.4 KB
- Stars: 13
- Watchers: 2
- Forks: 2
- Open Issues: 3
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
## Svelte Simple Icons
[![js-standard-style](https://img.shields.io/badge/code%20style-standard-brightgreen.svg)](http://standardjs.com) [![svelte-v3](https://img.shields.io/badge/svelte-v3-blueviolet.svg)](https://svelte.dev)
Based on [Svelte Eva Icons](https://github.com/dylanblokhuis/svelte-eva-icons)
## Install
```bash
yarn add --dev svelte-simple-icons
```
or use NPM
```bash
npm install --save-dev svelte-simple-icons
```## Usage
Unused icons will get removed with tree shaking in bundlers like webpack and rollup.
```html
// Only import what you need!
import { RIcon, HuluIcon, ... } from 'svelte-simple-icons'
```Use the svg name when importing, and convert it to {PascalCase}Icon.
For instance, `.NET` on the creators site has an SVG name of `dot-net.svg`, so should be imported as ``
See all icons here: https://simpleicons.org/### Exceptions
The one notable exception to the rule above is the 500px icon:
```html
import { FiveHundredPxIcon } from 'svelte-simple-icons'
```### Styling
You can add CSS classes icons by passing a `styleClass` attribute:```html
```