F
F
fuckman2015-08-25 11:13:21
JavaScript
fuckman, 2015-08-25 11:13:21

How to implement authorization on the backbone?

What is the best way to implement backbone authorization with JWT from an architectural point of view? Is it better to make the models have a method for authorization or rewrite Backbone.sync so that it can deal with it there?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
K
Konstantin Kitmanov, 2015-08-25
@k12th

I would do it through Backbone.sync. Firstly, there is nothing for models to know about it. Secondly, in this way there will be one less base class in the inheritance chain.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question