question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Feature Request / Tag SVG elements with lucide-specific classes

See original GitHub issue

Tagging SVG icon elements with lucide specific classes like

<svg class="lucide lucide-{icon-name}">…</svg>

would make much more easier to reference them from CSS stylesheets, in order for instance to:

  • factor app-wide sizing / stroke properties
  • tweak sizing / alignment for specific icons

P.S. Suggestion born from a real-world struggle in keeping icons aligned with button labels using fonts with an atypical baseline…

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Reactions:3
  • Comments:11 (11 by maintainers)

github_iconTop GitHub Comments

1reaction
queenvictoriacommented, Sep 10, 2021

Thanks @ericfennis

For a user new to yarn: following are complete instructions for testing a package from a monorepo.

WARNING: Apple silicon follow this guide first.

Outside your project

$ git clone git@github.com:lucide-icons/lucide.git
$ cd lucide
$ npm install --global yarn
$ yarn install # May fail on Apple silicon see warning above.
$ yarn lucide-vue build
$ cd packages/lucide-vue
$ yarn link

Inside your project

$ yarn link lucide-vue

Note: After this you may experience a large number of linting errors. This is because the package is outside your app root. There are a number of ways to fix this. One way is to exclude lucide-vue from linting.

$ echo lucide-vue >> .eslintignore
0reactions
queenvictoriacommented, Sep 17, 2021

Oh sweet!

Read more comments on GitHub >

github_iconTop Results From Across the Web

class - SVG: Scalable Vector Graphics - MDN Web Docs
Assigns a class name or set of class names to an element. You may assign the same class name or names to any...
Read more >
Document Structure — SVG 2
An SVG document fragment consists of any number of SVG elements contained within an 'svg' element. An SVG document fragment can range from...
Read more >
No SVG tag for email templates - Adobe XD: Feature Requests
No SVG tag for email templates ... Currently Adobe Xd relies on the <svg> tag to create some elements. This is great, especially...
Read more >
SVG Elements and Attributes - O'Reilly Design System
class #. A set of identifiers that describe custom features of this element, which it might share with other elements. Used in CSS...
Read more >
HTML SVG Graphics - W3Schools
SVG stands for Scalable Vector Graphics; SVG is used to define graphics for the Web; SVG is a ... The HTML <svg> element...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found