I am making a calculator that sends the numbers and math function in the text field to my server with body-parser but the function sent is a string and I can't calculate it. lets say my input is 3+5 and body-parser sends me a string "3+5" how can i make that string a number 3 and a number 5 to then add together or maybe even covert the whole function so it calculates right away?
I have tried to take out the + sign but then instead of 3+5 it's just 35