Skip to content
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

Recruitment task- Julia Bartosik #11

Open
wants to merge 5 commits into
base: main
Choose a base branch
from

Conversation

juliabartosik
Copy link

Recruitment task- Julia Bartosik

@juliabartosik juliabartosik changed the title Julia bartosik Recruitment task- Julia Bartosik May 15, 2023
Added app link
Comment on lines +23 to +31
const convertCurrency = () => {
fetch(`https://api.nbp.pl/api/exchangerates/rates/A/${fromCurrency}/?format=json`)
.then(response => response.json())
.then(data => {
const rate = data.rates[0].mid;
setConvertedAmount((amount * rate).toFixed(2));
})
.catch(error => console.log(error));
};
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ta metoda wyciąga kurs danej waluty w przeliczeniu na złotego, aby przeliczyć kurs waluty A w stosunku do waluty B, należy w równaniu uwzględnić również kurs złotego . W tym momencie 1EUR daje 4.53USD, co jest nieprawdą

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants