You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
There is an error in the App.js file where the InputBox component's onCurrencyChange prop incorrectly uses setAmount instead of setFrom. This causes the amount to be set rather than updating the currency. This needs to be corrected to ensure the currency selection updates properly.
Steps to Reproduce:
Clone the repository and set up the project.
Run the application.
Navigate to the section where the "From" currency input is located.
Try changing the currency in the "From" field.
Expected Behavior:
When the currency is changed in the "From" input, the setFrom state update function should be called to update the currency.
Actual Behavior:
The setAmount state update function is called instead, which incorrectly updates the amount rather than the currency.
Code Snippet:
Here is the specific part of the code with the error and the proposed fix:
There is an error in the App.js file where the InputBox component's onCurrencyChange prop incorrectly uses setAmount instead of setFrom. This causes the amount to be set rather than updating the currency. This needs to be corrected to ensure the currency selection updates properly.
Steps to Reproduce:
Expected Behavior:
When the currency is changed in the "From" input, the setFrom state update function should be called to update the currency.
Actual Behavior:
The setAmount state update function is called instead, which incorrectly updates the amount rather than the currency.
Code Snippet:
Here is the specific part of the code with the error and the proposed fix:
The text was updated successfully, but these errors were encountered: