I am working on Angularjs
. There are two type of users on my website.
- Guest users
- Logged in users
Suppose there are 12 views in my Angular app. I want to render only 1 view for Guest user and 12 views for Logged in users.
As far as i read somewhere, Angularjs converts all the files(js,html) in single js then loads it (Correct me if i am wrong) . So, for Guest user it will also render the codes of rest 11 views which i do not want to render which make app little slow. I could use if/else statements to render view according to condition but still it will render rest 11 views for Guest users.
The only workaround i am seeing is to make two apps. Is it possible in Angularjs to define only 1 view for guest and 12 for logged in user in Single App??