Reputation: 3946
The idea is that both will be using similar resources (firebase tables, environment files, etc. But at the same time ionic will use its own mobile UI whereas the normal angular4 project will use bootstrap.
If it's possible I would appreciate to hear how you'd recommend doing it. If not, then what the alternatives would be.
Upvotes: 2
Views: 228
Reputation: 2726
Yes, it is possible and I would recommend going about it using git submodules
.
Submodules
It often happens that while working on one project, you need to use another project from within it. Perhaps it’s a library that a third party developed or that you’re developing separately and using in multiple parent projects. A common issue arises in these scenarios: you want to be able to treat the two projects as separate yet still be able to use one from within the other.
Here’s an example. Suppose you’re developing a website and creating Atom feeds. Instead of writing your own Atom-generating code, you decide to use a library. You’re likely to have to either include this code from a shared library like a CPAN install or Ruby gem, or copy the source code into your own project tree. The issue with including the library is that it’s difficult to customize the library in any way and often more difficult to deploy it, because you need to make sure every client has that library available. The issue with copying the code into your own project is that any custom changes you make are difficult to merge when upstream changes become available.
Git addresses this issue using submodules. Submodules allow you to keep a Git repository as a subdirectory of another Git repository. This lets you clone another repository into your project and keep your commits separate.
In essence you could have the shared data (environment variables, providers, etc) as a git submodule and include that in both the spearate Ionic and Angular frontends and use it from there.
You can think of git submodules like an npm package on steroids. The best part of it is that:
You can learn more about git submodules here.
Upvotes: 2