I was experimenting with the class declaration syntax of ES6 / ES- 2015, and could not declare properties, only methods:
class Teste {
constructor() {
}
metodo() {
}
// não funciona:
//propriedade: valor
}
Is there any way to declare instance properties in the body of the class? If it does not exist, what would be the justification for it being designed like this?