-
Notifications
You must be signed in to change notification settings - Fork 77
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Use web3icons #143
Use web3icons #143
Conversation
@0xa3k5 is attempting to deploy a commit to the BuidlGuidl Team on Vercel. A member of the Team first needs to authorize it. |
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me! The only concern for me is the library size
But makes sense to have it large since we have svg images in their. Also once advantage is that when people add chain from "other chain" they get the image out of box. Also I don't see any delay in website initial load (maybe next optimising thing at build time)
@technophile-04 the |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There is a minor layout shift but that could be because of my connection!!
we can fix that later if it becomes a problem
lgtm!
hey @technophile-04 & @portdeveloper I've just released a new version to the @web3icons/react that reduces it's dependencies (mainly inquirer) as well as introduces some more network icons, thought I'd commit to the PR while it's still open. |
Thank you for the hard work! I think what you're doing with web3icons is amazing! Hyped to get this merged. 🫡 |
Tysm @0xa3k5! For so quick updates! |
Just curious can't we use the same component for og images? Looking at abi.ninja/packages/nextjs/pages/api/og.tsx Line 210 in dd901af
It seems that we are using jsx here right? |
I have just tested it and It does not work. This could be well due to how image generation works in vercel/og, since it does not have access to the default nodejs runtime. |
The |
Since you have abi.ninja on your computer I suggest that you go to: Because this is just vercel/og, anything you put here should work: You can do a and check this route as an example: If you haven't changed anything you will see: From this stage you can modify the returned ImageResponse. If you need something simple, maybe this could work better for you: |
oh tyvm @portdeveloper I'm seeing what the issue is: The |
@0xa3k5 Thanks for putting in the hard work and dissecting the issue! |
Description
uses
NetworkIcon
from web3icons in the NetworksDropdown component. The NetworkIcon component relies on a chain's id (chainId
) so it is future proof, most of the chains in theviem
is supported in the library, and library is growing.I've specifically did not delete the .svg images under the public folder, from what I can tell, they are used in OG image generation, I'm not 100% sure if there are any other place that uses the
.icon
properties that relies on the.svg
files. Feel free to expand on the PR to include them if you think it's necessary.https://share.cleanshot.com/G3p8vj1s
Additional Information
Related Issues
Closes #117
Your ENS/address: a3k5.eth