I am new to AMP and have been asked to add amp to an already developed angular website. I have also read that AMP Keep all third-party JavaScript out of the critical path But I am not sure whether it is possible or not.And if possible can you share some links for that. Any help is welcome
Assuming you already have a site with Angular pages like:
Then you can create AMPs like:
1.html can use Angular and client-side javascript but 1.amp.html should be a representation of the same content but produced server-side rather than by using Angular javascript inside it. Follow the steps in here: https://ampbyexample.com/introduction/how_to_publish_amps/ and you should be fine.
You can certainly link to AMP pages from your existing site, but the specification for AMP is a limited subset of HTML elements and there are restrictions on what JavaScript you can have running on your page. I don't believe you can have an AMP page powered by Angular.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With