https://github.com/seregpie/vuesvg
Loads a SVG image as an inline SVG.
https://github.com/seregpie/vuesvg
component svg vue
Last synced: about 2 months ago
JSON representation
Loads a SVG image as an inline SVG.
- Host: GitHub
- URL: https://github.com/seregpie/vuesvg
- Owner: SeregPie
- License: mit
- Created: 2018-06-27T14:07:38.000Z (almost 7 years ago)
- Default Branch: master
- Last Pushed: 2019-04-04T11:18:17.000Z (about 6 years ago)
- Last Synced: 2025-03-31T09:13:43.692Z (about 2 months ago)
- Topics: component, svg, vue
- Language: JavaScript
- Homepage:
- Size: 16.6 KB
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# VueSvg
Loads a SVG image as an inline SVG.
## setup
### npm
```shell
npm i @seregpie/vuesvg
```### ES module
Register the component globally.
```javascript
import Vue from 'vue';
import VueSvg from '@seregpie/vuesvg';Vue.component(VueSvg.name, VueSvg);
```*or*
Register the component in the scope of another component.
```javascript
import VueSvg from '@seregpie/vuesvg';export default {
components: {
[VueSvg.name]: VueSvg,
},
};
```### browser
```html
```
If Vue is detected, the component will be registered automatically.
## usage
```html
```