3

Besides the added convenience, there is no reason for my landing page to be in an angular application with the added load performance overhead of loading the main bundle.

Is it possible to have a static landing page and lazy loading the rest of the angular app once the user clicks on any of the links that leave the landing page into the configured angular routes?

0

1 Answer 1

2

You can build a simple landing page pure in javascript whatever. If the user click on a special link, you will call your angular application. So you have an instance response for the user, after user interaction you can load your angular application

Sign up to request clarification or add additional context in comments.

4 Comments

Would the landing page be built within angular and just not trigger the loads yet or would the angular app live in a different directory?
the angular-app should be in a different directory. Your landing page is a "simple" old school, html5, css3, javascript page. Of course, you can also build app an simple, small angular application as landing app, but you will have the angular stack overhead. If you really want to use a library on your landing page, check vue2. Its a small library (based on react)
@Reed did you ever figure this out? I am in the same predicament. I want to create an Angular app with a static html/js landing page such that I can easily change out the landing page to a/b test. I am also curious about your directory structure and how you deployed said app.
@Reza yes, I had to change the base href of the angular app to ./ and put the app in a directory that the landing page links to. stackoverflow.com/a/41308342/7896203

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.