Perhaps you want something like this:
class Select {
constructor(el,input){
this.el = el;
this.input = input
}
input;
autoExecute(){
// IThis needcode thesewill functionautoExecute towhen executeyou immediately;construct an object
console.log(this.input);
}
}
You can run this code in the console with something like:
var a = new Select("hi", "bye");
a.autoExecute();