Answer the question
In order to leave comments, you need to log in
How to implement LocalStorage in Angular 2 without HTTP?
I need to create authentication with LocalStorage in Angular 2 + Typescript.
I need advice how can I do this without HTTP? How can I initialize this repository to work with it?
I would appreciate links with examples.
Answer the question
In order to leave comments, you need to log in
Even I did not quite understand what the problem is? In what sense how to initialize?
localStorage.setItem('token', 'some token');
const token = localStorage.getItem('token');
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question