React Calculator failing tests, do I need to re-write?

Afternoon, is there anyone who could point me in the right direction on how to pass this test? I have read its a React 18 problem but can’t figure out what I need to do. Am I just going to have to re-write it in Javascript for it to pass?

Many thanks

Ive done so more than once youll have to weight the pros and cons moving forward was my answer. Good luck

The element with the id display should be used for the current input and the calculated result.

If you want to do what the demo project does, inspect the DOM in the browser to see how it uses the two elements.

https://javascript-calculator.freecodecamp.rocks/

1 Like

Thanks, took a bit of re-working but not too painful. This has also taught me the importance of adding notes to my code

All passed now :grinning: