im trying to create an object on an onClick event of a button. Don\'t know if its necessary but I declared the button in x.html and got the constructor of the object in y.js