I have a javascript file named sum.js
var addNumber = function (a,b){
return a + b;
}
exports.addNumber = addNumber;
I want to use same sum.js
file's addNumber
function in nodeJS
and in Angular 5
. How can I do it. Is there any ways to do it?
Your help will be highly appreciated.