Slide 67
Slide 67 text
Fake Cache
Comment posted
CommentId: ABC123
This is a stupid question!!!
var localComments = JSON.parse(localStorage.getItem('comments')) || [];
var newComment = {
'questionId': "blah";,
'commentId': "ABC123";,
'commentText': commentText,
'isFromLocal': true
};
localComments.push(newComment);
localStorage.setItem('comments', JSON.stringify(localComments));
@dasiths