From ae43473aa6445495e583fe3eeff8499a61b256b4 Mon Sep 17 00:00:00 2001
From: Nicolas Boyer <52313840+boyer-nicolas@users.noreply.github.com>
Date: Fri, 22 Nov 2024 10:07:48 +0100
Subject: [PATCH 01/29] Added documentation about Svelte 5 (#2621)
Svelte 5 specifics including removing the "ComponentType" typescript type as components are now static.
Also merged some imports into one-liners as we don't need to import each icon in a single line.
---
docs/guide/packages/lucide-svelte.md | 181 +++++++++++++++++++++------
1 file changed, 144 insertions(+), 37 deletions(-)
diff --git a/docs/guide/packages/lucide-svelte.md b/docs/guide/packages/lucide-svelte.md
index 77e07ea6b6..77877ea203 100644
--- a/docs/guide/packages/lucide-svelte.md
+++ b/docs/guide/packages/lucide-svelte.md
@@ -87,54 +87,95 @@ The package includes type definitions for all icons. This is useful if you want
### TypeScript Example
+#### Svelte 4
+
```svelte
{#each menuItems as item}
-
-
+ Icons + · + Guide + · + Packages + · + License + · + Showcase +
# Lucide -Community-run fork of [Feather Icons](https://github.com/feathericons/feather), open for anyone to contribute icons. - -It began after growing dissatisfaction with the [Feather Icons](https://github.com/feathericons/feather) project moderation. With over 300+ open issues and over 100+ open PRs, the Feather Icons project has been abandoned. This unfortunately means that hundreds of developers and designers wasted their time contributing to Feather Icons with no chance of PRs being accepted. - -Lucide is trying to expand the icon set as much as possible while staying faithful to the original simplistic design language. We do this as a community of devs and designers and hope that you'll join us! - -### Why choose Lucide over Feather Icons - -- More icons to work with: Lucide already has hundreds of icons more than Feather does. -- Official libraries and integrations with popular frameworks and design tools. -- Well maintained code base. -- Active community, regularly growing and improving the set. - -## Table of Contents - -- [Usage](#usage) - - [Web](#web) - - [React](#react) - - [React Native](#react-native) - - [Vue 2](#vue-2) - - [Vue 3](#vue-3) - - [Angular](#angular) - - [Preact](#preact) - - [Static (svg sprite, font, icons ..)](#static-svg-sprite-font-icons-) - - [Figma](#figma) - - [Laravel](#laravel) - - [Svelte](#svelte) - - [Solid](#solid) - - [Hyva](#hyva) - - [Eleventy](#eleventy) -- [Contributing](#contributing) -- [Community](#community) -- [License](#license) -- [Credits](#credits) -- [Sponsors](#sponsors) - -## Usage - -At its core, Lucide is a collection of [SVG](https://svgontheweb.com/#svg) files. This means that you can use Lucide icons in all the same ways you can use SVGs (e.g. `img`, `background-image`, `inline`, `object`, `embed`, `iframe`). Here's a helpful article detailing the many ways SVGs can be used on the web: [SVG on the Web – Implementation Options](https://svgontheweb.com/#implementation) - -The following are additional ways you can use Lucide. -With the Javascript library you can easily incorporate the icon you want in your webpage. - -### Web - -Implementation of the lucide icon library for web applications. - -```sh -npm install lucide -``` - -or - -```sh -yarn add lucide -``` - -For more details, see the [documentation](https://github.com/lucide-icons/lucide/tree/main/packages/lucide#lucide). - -### React - -Implementation of the lucide icon library for react applications. - -```sh -yarn add lucide-react -``` - -or - -```sh -npm install lucide-react -``` - -For more details, see the [documentation](https://github.com/lucide-icons/lucide/tree/main/packages/lucide-react#lucide-react). - -### React Native - -Implementation of the lucide icon library for React Native applications. - -```sh -yarn add lucide-react-native -``` - -or - -```sh -npm install lucide-react-native -``` - -For more details, see the [documentation](https://github.com/lucide-icons/lucide/tree/main/packages/lucide-react-native#lucide-react-native). - -### Vue 2 - -Implementation of the lucide icon library for vue applications. - -```sh -yarn add lucide-vue -``` - -or - -```sh -npm install lucide-vue -``` - -For more details, see the [documentation](https://github.com/lucide-icons/lucide/tree/main/packages/lucide-vue#lucide-vue). - -### Vue 3 - -Implementation of the lucide icon library for vue applications. - -```sh -yarn add lucide-vue-next -``` - -or - -```sh -npm install lucide-vue-next -``` +Lucide is an open-source icon library that provides 1000+ vector (svg) files for displaying icons and symbols in digital and non-digital projects. The library aims to make it easier for designers and developers to incorporate icons into their projects by providing several official [packages](https://lucide.dev/packages) to make it easier to use these icons in your project. -For more details, see the [documentation](https://github.com/lucide-icons/lucide/tree/main/packages/lucide-vue-next#lucide-vue-next). +## Packages -### Angular - -```sh -yarn add lucide-angular -``` - -or - -```sh -npm install lucide-angular -``` - -For more details, see the [documentation](https://github.com/lucide-icons/lucide/tree/main/packages/lucide-angular#lucide-angular). - -### Preact - -Implementation of the lucide icon library for preact applications. - -```sh -yarn add lucide-preact -``` - -or - -```sh -npm install lucide-preact -``` - -For more details, see the [documentation](https://github.com/lucide-icons/lucide/tree/main/packages/lucide-preact#lucide-preact). - -### Static (svg sprite, font, icons ..) - -Assets: -[Font Files](https://github.com/lucide-icons/lucide/releases/latest) -[SVG Files](https://github.com/lucide-icons/lucide/releases/latest) -[SVG Sprite](https://cdn.jsdelivr.net/npm/lucide-static@latest/sprite.svg) - -NPM package - -```sh -yarn add lucide-static -``` - -or - -```sh -npm install lucide-static -``` +| | Package | Version & Downloads | Links | +| --- | --- | --- | --- | +| | `lucide` | [![npm](https://img.shields.io/npm/v/lucide)](https://www.npmjs.com/package/lucide) ![NPM Downloads](https://img.shields.io/npm/dw/lucide) | [Docs](https://lucide.dev/guide/packages/lucide) [Source](./packages/lucide) | +| | `lucide-react` | [![npm](https://img.shields.io/npm/v/lucide-react)](https://www.npmjs.com/package/lucide-react) ![NPM Downloads](https://img.shields.io/npm/dw/lucide-react) | [Docs](https://lucide.dev/guide/packages/lucide-react) [Source](./packages/lucide-react) | +| | `lucide-vue-next` | [![npm](https://img.shields.io/npm/v/lucide-vue-next)](https://www.npmjs.com/package/lucide-vue-next) ![NPM Downloads](https://img.shields.io/npm/dw/lucide-vue-next) | [Docs](https://lucide.dev/guide/packages/lucide-vue-next) [Source](./packages/lucide-vue-next) | +| | `lucide-svelte` | [![npm](https://img.shields.io/npm/v/lucide-svelte)](https://www.npmjs.com/package/lucide-svelte) ![NPM Downloads](https://img.shields.io/npm/dw/lucide-svelte) | [Docs](https://lucide.dev/guide/packages/lucide-svelte) [Source](./packages/lucide-svelte) | +| | `lucide-solid` | [![npm](https://img.shields.io/npm/v/lucide-solid)](https://www.npmjs.com/package/lucide-solid) ![NPM Downloads](https://img.shields.io/npm/dw/lucide-solid) | [Docs](https://lucide.dev/guide/packages/lucide-solid) [Source](./packages/lucide-solid) | +| | `lucide-preact` | [![npm](https://img.shields.io/npm/v/lucide-preact)](https://www.npmjs.com/package/lucide-preact) ![NPM Downloads](https://img.shields.io/npm/dw/lucide-preact) | [Docs](https://lucide.dev/guide/packages/lucide-preact) [Source](./packages/lucide-preact) | +| | `lucide-react-native` | [![npm](https://img.shields.io/npm/v/lucide-react-native)](https://www.npmjs.com/package/lucide-react-native) ![NPM Downloads](https://img.shields.io/npm/dw/lucide-react-native) | [Docs](https://lucide.dev/guide/packages/lucide-react-native) [Source](./packages/lucide-react-native) | +| | `lucide-angular` | [![npm](https://img.shields.io/npm/v/lucide-angular)](https://www.npmjs.com/package/lucide-angular) ![NPM Downloads](https://img.shields.io/npm/dw/lucide-angular) | [Docs](https://lucide.dev/guide/packages/lucide-angular) [Source](./packages/lucide-angular) | +| | `lucide-static` | [![npm](https://img.shields.io/npm/v/lucide-static)](https://www.npmjs.com/package/lucide-static) ![NPM Downloads](https://img.shields.io/npm/dw/lucide-static) | [Docs](https://lucide.dev/guide/packages/lucide-static) [Source](./packages/lucide-static) | ### Figma @@ -196,68 +50,6 @@ Visit [Figma community page](https://www.figma.com/community/plugin/939567362549 -### Laravel - -Implementation of Lucide icon's using `blade-icons` for Laravel based projects. - -```sh -composer require mallardduck/blade-lucide-icons -``` - -For more details, see the [documentation](https://github.com/mallardduck/blade-lucide-icons/blob/main/README.md). - -### Svelte - -Implementation of the lucide icon library for Svelte applications. - -```sh -yarn add lucide-svelte -``` - -or - -```sh -npm install lucide-svelte -``` - -For more details, see the [documentation](https://github.com/lucide-icons/lucide/tree/main/packages/lucide-svelte#lucide-svelte). - -### Solid - -Implementation of the lucide icon library for solid applications. - -```sh -yarn add lucide-solid -``` - -or - -```sh -npm install lucide-solid -``` - -For more details, see the [documentation](https://github.com/lucide-icons/lucide/tree/main/packages/lucide-solid#lucide-solid). - -### Hyva - -Implementation of Lucide icon's using Hyvä's svg php viewmodal to render icons for Magento 2 Hyva theme based projects. - -```sh -composer require siteation/magento2-hyva-icons-lucide -``` - -For more details, see the [documentation](https://github.com/Siteation/magento2-hyva-icons-lucide/blob/main/README.md). - -### Eleventy - -Using this plugin, Eleventy projects can incorporate Lucide icons. it makes it simple to use Lucide icons into your themes via shortcodes, improving your website's overall usability and visual appeal. - -```sh -npm install @grimlink/eleventy-plugin-lucide-icons -``` - -For more details, see the [documentation](https://github.com/GrimLink/eleventy-plugin-lucide-icons/blob/main/README.md). - ## Contributing For more info on how to contribute please see the [contribution guidelines](https://github.com/lucide-icons/lucide/blob/main/CONTRIBUTING.md). diff --git a/docs/.vitepress/data/packageData.json b/docs/.vitepress/data/packageData.json index 613ed60e79..c4a62adf16 100644 --- a/docs/.vitepress/data/packageData.json +++ b/docs/.vitepress/data/packageData.json @@ -31,24 +31,8 @@ } ] }, - "lucide-vue": { - "order": 2, - "icon": "vue", - "shields": [ - { - "alt": "npm", - "src": "https://img.shields.io/npm/v/lucide-vue", - "href": "https://www.npmjs.com/package/lucide-vue" - }, - { - "alt": "npm", - "src": "https://img.shields.io/npm/dw/lucide-vue", - "href": "https://www.npmjs.com/package/lucide-vue" - } - ] - }, "lucide-vue-next": { - "order": 3, + "order": 2, "icon": "vue-next", "shields": [ { @@ -64,7 +48,7 @@ ] }, "lucide-svelte": { - "order": 4, + "order": 3, "icon": "svelte", "shields": [ { @@ -95,24 +79,8 @@ } ] }, - "lucide-preact": { - "order": 5, - "icon": "preact", - "shields": [ - { - "alt": "npm", - "src": "https://img.shields.io/npm/v/lucide-preact", - "href": "https://www.npmjs.com/package/lucide-preact" - }, - { - "alt": "npm", - "src": "https://img.shields.io/npm/dw/lucide-preact", - "href": "https://www.npmjs.com/package/lucide-preact" - } - ] - }, "lucide-react-native": { - "order": 6, + "order": 5, "icon": "react-native", "shields": [ { @@ -128,7 +96,7 @@ ] }, "lucide-angular": { - "order": 7, + "order": 6, "icon": "angular", "shields": [ { @@ -143,6 +111,22 @@ } ] }, + "lucide-preact": { + "order": 7, + "icon": "preact", + "shields": [ + { + "alt": "npm", + "src": "https://img.shields.io/npm/v/lucide-preact", + "href": "https://www.npmjs.com/package/lucide-preact" + }, + { + "alt": "npm", + "src": "https://img.shields.io/npm/dw/lucide-preact", + "href": "https://www.npmjs.com/package/lucide-preact" + } + ] + }, "lucide-static": { "order": 8, "icon": "svg", diff --git a/docs/.vitepress/sidebar.ts b/docs/.vitepress/sidebar.ts index 5833648f07..ad796b9626 100644 --- a/docs/.vitepress/sidebar.ts +++ b/docs/.vitepress/sidebar.ts @@ -72,10 +72,6 @@ const sidebar: UserConfig