I have this code in my vue-js app:
methods: {
onSubmit() {
ApiService.post(\'auth/sign_in\', {
email: this.email,
password: this.pa
U can rewrite that line as [this.message] = res.response.data.errors;
and that es-lint error will go off. See this example for better understanding
var x = {
y: {
z: {
w: [3, 4]
}
}
};
function foo() {
[this.a] = x.y.z.w
console.log(this.a);
}
foo() // prints 3
For more information about array destructuring please see here