Angular 2+ Co-existing with PHP

41 Views Asked by At

Given the title, what readily comes to mind is a PHP REST back-end to the ng app but my needs are different.

I have a PHP app that I wish to convert piecemeal into ng2+. The architecture of the app is that the menu is the main app window which as you select menu items opens the relevant PHP code in a subframe. A bit old school but I don’t want this changed.

Naturally the menu app can load anything into the subframe and as at now some sub-apps are pure html pages (not even PHP.) So my desire is to have the new (or converted) ng2 code load up in the subframe. This of course being a single-page app that gets reinitialized each time likely means slow response if the menu loads a PHP page and then comes back to the ng2+ page.

What specific ng2 features will let this happen with like no noticeable delays (ie it feels like one and same app?) Is this what server side rendering can do (even though that’s not available for PHP yet I gather) or is it only local variables on the client side I need to worry about?

Would appreciate any guidance.

0

There are 0 best solutions below