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.

Auto-import based on prop binding pattern

See original GitHub issue

Thanks for this amazing plugin. I’m using auto-import via unplugin-components, unicons (prefix is ‘uil’) iconset in the below example (https://stackblitz.com/github/techakayy/vuetify3-beta-unplugin-icons?file=src%2FApp.vue).

So, basically, <i-uil-android> will auto-import just fine as it uses the {prefix}-{collection}-{icon} tag pattern.

But, if I’m binding the icon as a prop (uilShoppingCart in the below example), then looks like I need to manually import the icon.

Is it possible to support auto-import based on prop-binding pattern as well, for example {prefix}{Collection}{Icon} (camelCase equivalent)?

image

Issue Analytics

  • State:closed
  • Created a year ago
  • Comments:9

github_iconTop GitHub Comments

1reaction
TechAkayycommented, May 20, 2022

Unocss icons preset is an amazing combo for vuetify 😃 I think I will leave unplugin-icons behind for now. Thanks a lot for suggesting it…

https://stackblitz.com/github/techakayy/vuetify3-beta-unocss-icons

image

1reaction
userquincommented, May 20, 2022

vuetify should add a way to use custom icons via slot instead prop

Read more comments on GitHub >

github_iconTop Results From Across the Web

vue.js - With Nuxt's auto import of components, how to use the ...
When you use the binding sign : the template sees for a defined property inside your component instance, if you don't provide that...
Read more >
Auto import the prop-types package when using PropTypes ...
From my side, I resolve issue by a crazy trick, I create file with name propTypes.js and I import and export library in...
Read more >
Announcing TypeScript 4.8 RC - Microsoft Developer Blogs
When TypeScript sees the binding pattern [a, b, c] , it creates the type [any, any, any] , and that type gets picked...
Read more >
vscode will not auto import node modules packages correctly
I meant defaulting to Node.js style path lookups in all module types. Use module to specify the file format/syntax, not the path lookup....
Read more >
Python import: Advanced Techniques and Tips
You base this on the PyYAML package, which must be installed from PyPI: ... see how to use namespace packages in a proper...
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