Installations
npm install vue-cli-plugin-svg-sprite-loader
Developer Guide
Typescript
No
Module System
CommonJS
Node Version
12.18.3
NPM Version
6.14.6
Score
67.6
Supply Chain
86.4
Quality
75.6
Maintenance
100
Vulnerability
100
License
Releases
Unable to fetch releases
Contributors
Unable to fetch Contributors
Languages
Vue (70.96%)
JavaScript (26.47%)
TypeScript (2.57%)
Developer
shooterRao
Download Statistics
Total Downloads
37,013
Last Day
5
Last Week
19
Last Month
68
Last Year
2,362
GitHub Statistics
12 Stars
13 Commits
2 Forks
2 Watching
1 Branches
1 Contributors
Bundle Size
494.00 B
Minified
308.00 B
Minified + Gzipped
Package Meta Information
Latest Version
2.0.1
Package Id
vue-cli-plugin-svg-sprite-loader@2.0.1
Unpacked Size
9.76 kB
Size
3.68 kB
File Count
12
NPM Version
6.14.6
Node Version
12.18.3
Total Downloads
Cumulative downloads
Total Downloads
37,013
Last day
0%
5
Compared to previous day
Last week
-24%
19
Compared to previous week
Last month
-39.3%
68
Compared to previous month
Last year
-52.1%
2,362
Compared to previous year
Daily Downloads
Weekly Downloads
Monthly Downloads
Yearly Downloads
No dependencies detected.
vue-cli-plugin-svg-sprite-loader
vuecli3 svg-sprite-loader 插件,让你轻松使用svg图标
安装
vue add svg-sprite-loader
使用
1<SvgIcon name="vue" />
组件参数
参数 | 描述 | 类型 |
---|---|---|
name | svg图标文件名(必填) | String |
size | 大小(支持rem,比如直接写12rem) | Number or String |
color | 颜色(单色图标才有效且path不能有fill属性) | String |
width | svg宽度 | String |
height | svg高度 | String |
svg-sprite-loader 插件参数自定义
在vue.config.js:
1module.exports = { 2 pluginOptions: { 3 svgSpriteLoader: { 4 // directory 5 dir: path.resolve(__dirname, 'src/icon'), 6 // test rule 7 test: /\.svg$/, 8 // https://github.com/JetBrains/svg-sprite-loader#configuration 9 options: { 10 symbolId: 'icon-[name]' 11 } 12 } 13 } 14}
版本更新
1.0.2
- 新增svg图标预览页面
1.0.3
- 移除className属性,使用vue自带class合并写法
- 新增width、height属性,支持自定义宽高
- size支持rem
2.0.0
- 升级 svg-sprite-loader 为5.1.x版本
2.0.1
- 自动检测开发环境是js还是ts,注入不同的模板
No vulnerabilities found.
Reason
no binaries found in the repo
Reason
0 existing vulnerabilities detected
Reason
Found 0/13 approved changesets -- score normalized to 0
Reason
0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0
Reason
no SAST tool detected
Details
- Warn: no pull requests merged into dev branch
Reason
no effort to earn an OpenSSF best practices badge detected
Reason
security policy file not detected
Details
- Warn: no security policy file detected
- Warn: no security file to analyze
- Warn: no security file to analyze
- Warn: no security file to analyze
Reason
project is not fuzzed
Details
- Warn: no fuzzer integrations found
Reason
license file not detected
Details
- Warn: project does not have a license file
Reason
branch protection not enabled on development/release branches
Details
- Warn: branch protection not enabled for branch 'master'
Score
2.6
/10
Last Scanned on 2025-01-27
The Open Source Security Foundation is a cross-industry collaboration to improve the security of open source software (OSS). The Scorecard provides security health metrics for open source projects.
Learn More