I am currently working on a hybrid app using Typescript and I have been trying to figure out how to access a function in Typescript.
Here is an example of my code:
export class SuccessPage {
public removeRoom(){
console.log("removeroom");
}
}
function getRoom(){
var searchList = '';
....
searchList += ' <li id=\'' + result.Item[0].room_num + '\'>';
searchList += result.Item[i].dest_x + ', ' + result.Item[0].dest_y +
'<br><button class="removeRoom" onclick="removeRoom()"> </button></li>';
....
}
I am looking for a way to access the removeRoom
function. Can anyone guide me on how I can achieve this?