Socket
Socket
Sign inDemoInstall

unplugin-icons

Package Overview
Dependencies
Maintainers
2
Versions
88
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

unplugin-icons - npm Package Compare versions

Comparing version 0.13.0 to 0.13.1

38

package.json
{
"name": "unplugin-icons",
"version": "0.13.0",
"version": "0.13.1",
"description": "Access thousands of icons as components on-demand universally",

@@ -93,30 +93,30 @@ "homepage": "https://github.com/antfu/unplugin-icons",

"@antfu/install-pkg": "^0.1.0",
"@antfu/utils": "^0.4.0",
"@iconify/utils": "^1.0.20",
"@antfu/utils": "^0.5.0",
"@iconify/utils": "^1.0.23",
"debug": "^4.3.3",
"kolorist": "^1.5.1",
"local-pkg": "^0.4.0",
"unplugin": "^0.2.21"
"local-pkg": "^0.4.1",
"unplugin": "^0.3.2"
},
"devDependencies": {
"@antfu/eslint-config": "^0.14.0",
"@iconify/json": "^2.0.15",
"@antfu/eslint-config": "^0.16.1",
"@iconify/json": "^2.0.34",
"@iconify/types": "^1.0.12",
"@svgr/core": "^6.1.2",
"@svgr/core": "^6.2.1",
"@types/debug": "^4.1.7",
"@types/node": "^17.0.4",
"@typescript-eslint/eslint-plugin": "^5.8.0",
"@vue/compiler-sfc": "^3.2.26",
"@types/node": "^17.0.16",
"@typescript-eslint/eslint-plugin": "^5.11.0",
"@vue/compiler-sfc": "^3.2.30",
"bumpp": "^7.1.1",
"cross-env": "^7.0.3",
"eslint": "^8.5.0",
"esno": "^0.13.0",
"rollup": "^2.62.0",
"tsup": "^5.11.9",
"typescript": "^4.5.4",
"vite": "^2.7.6",
"vitest": "^0.0.113"
"eslint": "^8.8.0",
"esno": "^0.14.1",
"rollup": "^2.67.1",
"tsup": "^5.11.13",
"typescript": "^4.5.5",
"vite": "^2.7.13",
"vitest": "^0.2.8"
},
"peerDependencies": {
"@svgr/core": "^5.5.0",
"@svgr/core": ">=5.5.0",
"@vue/compiler-sfc": "^3.0.2",

@@ -123,0 +123,0 @@ "vue-template-compiler": "^2.6.12",

@@ -253,2 +253,40 @@ # unplugin-icons

<details>
<summary>Next.js</summary><br>
The `unplugin-icons` plugin should be configured on `next.config.js` configuration file:
```js
/** @type {import('next').NextConfig} */
module.exports = {
reactStrictMode: true,
webpack(config) {
config.plugins.push(
require('unplugin-icons/webpack')({
compiler: 'jsx',
jsx: 'react',
}),
);
return config;
},
};
```
Check instructions in the `Frameworks -> React` section below if you faced module import errors.
⚠️ **Warning:** to import an icon is necessary to explicitly add the `.jsx` extension to the import path, so that Next.js knows how to load it, by example:
```ts
import IconArrowRight from '~icons/dashicons/arrow-right.jsx';
// ^-- write `.jsx` to avoid
// https://github.com/antfu/unplugin-icons/issues/103
// ...some code later
<IconArrowRight />
```
See inside of `examples/next` for a working example project.
<br></details>
###### Frameworks

@@ -424,3 +462,3 @@

From `v0.12.24` you can also provide a transform callback to `FileSystemIconLoader`.
From `v0.13` you can also provide a transform callback to `FileSystemIconLoader`.

@@ -466,3 +504,3 @@ ```ts

> 💡 SVG Authoring Tips:
> - To make your icons color adaptable, set `fill="currentColor"` for `stroke="currentColor"` in your SVG.
> - To make your icons color adaptable, set `fill="currentColor"` or `stroke="currentColor"` in your SVG.
> - Leave the `height` and `width` unspecified, we will set them for you.

@@ -488,3 +526,3 @@

From version `v0.12.24` you can also customize each icon using `iconCustomizer` configuration option or using query params when importing them.
From `v0.13` you can also customize each icon using `iconCustomizer` configuration option or using query params when importing them.

@@ -551,7 +589,7 @@ The `query` param will take precedence over `iconCustomizer` and `iconCustomizer` over `configuration`.

<template>
<!-- width=4em and width=4em -->
<!-- width=4em and height=4em -->
<mdi-alarm-off />
<!-- width=4em and width=4em -->
<!-- width=4em and height=4em -->
<MdiAlarmOff />
<!-- width=1em and width=1em -->
<!-- width=1em and height=1em -->
<MdiAlarmOff2 />

@@ -588,3 +626,5 @@ </template>

Components({
resolvers: IconsResolver(),
resolvers: [
IconsResolver()
],
}),

@@ -640,3 +680,5 @@ Icons(),

Components({
resolvers: IconsResolver(),
resolvers: [
IconsResolver(),
]
}),

@@ -643,0 +685,0 @@ Icons(),

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc