[Vuejs]-How to convert html,js,css files into SFC using vue?

0👍

Since you are referencing the component data inside a nested function, you need to keep a scoped reference to the object.

function () {
var self = this;
var account = JSON.parse(localStorage.getItem('userdetails')).find(function(userdetails) {
    return (self.email === userdetails.email && self.password === userdetails.password) ? userdetails : null;
});

Leave a comment