@Joshdesign
Submitted
The most difficult for me was translate all on mobile version.
The beginning of the code.
How to make the @media part more agile?
@HectorMartinDama
@Joshdesign
Submitted
The most difficult for me was translate all on mobile version.
The beginning of the code.
How to make the @media part more agile?
@HectorMartinDama
Posted
Hello @Joshdesign the desing is very similiar to the original and the mobile version is very good. The media querys are correct. To be your first proyect in frontendmentor is great.
Marked as helpful
@alexgabriel8
Submitted
I accept any kind of feedback!
EDIT: Ignore the paragraph below, people already helped me fix my problem with Firefox!
Also I would like to know why my page ins't working correctly on Firefox. The page shows me an advice, but does not let me get another one.
@HectorMartinDama
Posted
Hello @alexgabriel8, in your request to the api use this:
fetch('https://api.adviceslip.com/advice/' + Math.floor(Math.random() * 200))
The random number is because if you do not indicate a specific advice, it does not work correctly, in your project change the advice when you click in the button five times
Marked as helpful
@Lohuama
Submitted
after published on github the image stopped showing, but local it shows
@HectorMartinDama
Posted
Hello @Lohuama, change the property "src" for this:
src="./images/image-qr-code.png"
You are missing the point, this indicates the main folder of the project.
@CrypticMango
Submitted
Just wanting to know if there was anything that I could have done better in my JS.
@HectorMartinDama
Posted
Hello @CrypticMango, your file js is good but I would change the api request into a function. That way you don't need to reload the page every time you click the button.
File js
function getApi(){
fetch('https://api.adviceslip.com/advice/' + Math.floor(Math.random() * 200))
.then(res => res.json())
.then(res => {
document.getElementById("phrase").innerHTML= '"' + res.slip.advice + '"'
document.getElementById("id").innerHTML= 'ADVICE #'+ res.slip.id
})
.catch(err => console.log(err))
}
The random number is because if you do not indicate a specific advice, it does not work correctly.
index.html
<button onclick="getApi()"></button>
Call the function in the button
For the rest it is perfect.
Marked as helpful
@HectorMartinDama
Submitted
Cualquier feedback es bienvenido.
@HectorMartinDama
Posted
Cualquier feedback es bienvenido.
@drEbison
Submitted
Please I will love to receive feedbacks if you notice any errors in my code. Thank you in anticipation.
@HectorMartinDama
Posted
Perfect 🤗
@Touret21
Submitted
Cualquier comentario con respecto al codigo es bienvenido 😄
@HectorMartinDama
Posted
@Touret21 para ser la primer challenge de FrontendMentor esta muy bien. Intenta respetar las medidas del componente. Por lo demás todo bien ☺️.
@eadq001
Submitted
to someone who's gonna review my code, thank you for your time. if you have some time available, i am hoping a feedback on what should i improve(e.g. git and github skills).
@HectorMartinDama
Posted
Hello eadq001, your code is good but the font-family it must be in (*) since the same font-family will be used throughout the page. To be your first Challenge in FrontendMentor it's very good. You can see my challenge in the profile.
Marked as helpful