Let's consider three small webapps developed using AngularDart as a front-end and a RESTful service as a back-end. Imagine that we want them unified into one big application while always being accessible individually. The big application is basically a menu with one item by small webapp and a content viewer rendering the chosen webapp.

What are the best practices to address such a use-case avoiding code repetition ?

有帮助吗?

解决方案

From your description it is not very clear to me how you want to split the three front-ends.

There are several ways depending on what you actually want to achieve.

You can put reusable GUI parts in components and put this components in a library package which you import in the application package.

If only you REST part should be reused put this code in a library package and import it on the application packages.

许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top