I know that a certain element or component will not be included in the DOM when the *ngIf
directive is set to false. Say I have a component that shows the admin tools and it should only be accessible to authorized users (administrators). Does the ngIf directive set to false prevent the javascript that makes up this component from being sent to the browser of unauthorized users? I am asking this because I don't want anyone unauthorized to be able to see my admin page somehow (maybe by decompiling). So is it available for everyone? And if so, how difficult is it to extract that admin component from the javascript files?
Thanks you,