Design comparison
Solution retrospective
The images didn't load when I tried using vercel or github pages. I also had difficulties with the active stats when the user hover above the image, it worked in very specific resolutions, but is not responsive as it could be.
Community feedback
- @Geo-BoldPosted 4 months ago
Hi Gabriel,
Congratulations for submiting a solution!
The reason your images aren't being loaded is because of invalid file paths. A file path tells the browser where to retreive the asset you wish to load and this can be done in one of two ways. If you want to load your images relative to the root of your project, you can use the following format:
/images/icon-view.svg
The first "/" represents your root directory which in your case is the "nft-preview-card-component-main" project directory. Another method is to create a file path that is relative to the file that is attempting to load the asset. In this case you can use "./" to reference the parent directory or use "../" to move up a directory. Using this format, you could use the following:
./images/icon-view.svg
This can be confusing when you first start using it, but some practice and LTW can help alleiviate these growing pains.
Hope this helps,
Geo
1
Please log in to post a comment
Log in with GitHubJoin our Discord community
Join thousands of Frontend Mentor community members taking the challenges, sharing resources, helping each other, and chatting about all things front-end!
Join our Discord