jeudi 22 février 2018

how to serve dynamic angular 1.5 pages

I want to serve an html page with angular but I want to show or hide a drop drown according to the user role (passes in the http header).

What are my ways to serve a dynamic html page?

1) Does angular render the html page on the server side or on the client side?

2) I thought about putting a cookie from the server side in the http response and then the angular will relate to this cookie.

but i think i can put this cookie only with a post-html filter. How can i find the interface for jersey or jetty post html filter?

I know the interface for pre-html filter:

public class AccessFilter implements Filter {
    private final static Logger logger = LoggingUtils.getLogger();
    @Override
    public void init(FilterConfig filterConfig) throws ServletException {
    }
    @Override
    public void doFilter(ServletRequest request, ServletResponse response, FilterChain chain) throws IOException, ServletException {
    }
    @Override
    public void destroy() {
    }




Aucun commentaire:

Enregistrer un commentaire