Closed lumosminima closed 8 months ago
On further examination, I'm abandoning this method because uno shortcuts are actually creating two separate classes one with i-check
and one with i-ms-check
with exactly same content. I guess this is just how uno works but I was trying to go 'CSS FIRST' and avoid a centralized icon object in JS and importing every time I need an icon. But even if it did ( I found this transformer unocss-transformer-alias which works) It is only build time aliasing so I can't store the alias in database as my app needs user selected icons at runtime and then I would need that object anyway. Basically, I keep confusing dynamic (runtime) and static (build time) when working with unocss 😅 and using a JS object with string names (and // @unocss-include
) is the right way to go in this context so #64 is all I need. Thank you!
Clear and concise description of the problem
I use shortcut's to alias and centralize app icons
=> { 'i-check' : 'i-ms-check' }
but preview doesn't work for unocss shortcuts.Suggested solution
I see that there is #64 which will solve the actual alias (i-ms-check) preview but it will be very nice if 'i-check' works too using same logic. Thank You!
Alternative
No response
Additional context
No response
Validations