Well... now I understand why I need to think before start coding something... this was beyond my knowledge :(
Khael
@i-am-KhaelAll comments
- @Aflora22Submitted over 2 years ago
- @i-am-KhaelSubmitted over 2 years ago
Everyone's feedback is always welcome..
@i-am-KhaelPosted over 2 years agoNote to everyone who will stumble upon my Solution, the API key I'm using reach its 1000 request limit since I'm using the Free Subscription..
0 - @karolbanatSubmitted over 2 years ago
Any feedback welcome
@i-am-KhaelPosted over 2 years agoGreat effort..
You can use this API endpoint https://api.adviceslip.com/advice/{id}, and generate a random number to replace id.. so that every time a user clicks on dice icon it will generate a random advice base on the id.. You can refer to my solution, https://www.frontendmentor.io/solutions/advice-generator-app-using-html5-css3-and-vanilla-js-S1-ZYT7Q5
Marked as helpful1 - @AnniK93Submitted over 2 years ago@i-am-KhaelPosted over 2 years ago
To resolve those accessibility issue,
- use an h1 instead of h3
- use main for the <main></main> landmark, then <section></section> to set landmark, then use div(s) inside section element.
and you can change api endpoint to https:// api.adviceslip.com/advice/id , then using Math.floor(Math.random * 255) to generate a random number for the id.
Great work and effort, though.
Marked as helpful0