question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Multi-App Configuration Issue

See original GitHub issue

Describe the bug https://ionicframework.com/docs/cli/configuration#config-file

In a multi-app project, apps share a single ionic.config.json file at the root of the repository instead of each app having their own.

Is this correct for the latest version of Ionic? I created the multi-apps with no-deps parameter and both apps also have their own ionic-config.json. Also .gitignore, tslint.json, package.json.

To Reproduce

  1. Create the root project. ionic start my-apps (blank template)
  2. Open the ionic.config.json and add the property "projects": {}.
  3. Create your apps by ionic start app1 --no-deps. (app1 and app2) (blank template)
  4. See that every app has its own ionic.config.json.

Expected behavior I’m not sure how the multi-app feature of Ionic works. I though I have a root project with all the project files like package.json and ionic.config.json. And the “sub-apps” only contains the sources without separated configuration files etc. Ok they can have a package.json. But why are there all the dependencies, even though the root dependencies should be used? Or do I understand something wrong? Or is the documentation wrong?

Screenshots If applicable, add screenshots to help explain your problem. image

Browser and OS (please complete the following information):

  • OS: Windows 10 Pro 64-bit (1903)
  • Ionic CLI: 5.2.5

Additional context I want to create one app base (root) with multi-app feature. Each apps should use the shared root components, services, etc. But an app can also have their own components. TSLint, TSConfig, Unit-Test-Config, gitignore, etc. should be shared. But currently each subapp have a own config. Exactly the same. DRY. Maybe this is a bug for the Ionic core repository or CLI? But perhaps it’s only a documentation issue. I don’t know who this should actual work. This is my first attempt of building a multi-app. But the fact is, each app in a multi-app project has its own ionic.config.json. The docs says there should only be one shared in the root. Or does this mean, I should delete the config files in my sub-apps?

Issue Analytics

  • State:open
  • Created 4 years ago
  • Comments:25 (5 by maintainers)

github_iconTop GitHub Comments

2reactions
josh-m-sharpecommented, Aug 21, 2019

“The Ionic CLI doesn’t have opinions about how you structure your monorepo.”

@dwieeb Then what is the Ionic CLI doing? Kinda detecting that ionic.config.json has a projects attr and stuffing config in that? And also honoring the --project flag and passing that onto lower level CLIs?

If the end result is that I still have to make manual changes to various angular.json(s) and modify them accordingly, shouldn’t I have to do that for my ionic.config.json(s) as well? And if I have to do that, why bother with this ionic CLI at all?

What’s extremely difficult to get past is that the docs as they stand today leave us with a non-functioning app. I understand there’s a world of flexibility in setting up a monorepo, so maybe the CLI can’t just create one, but if that’s the case, could we work to build some example apps that others could leverage as a starting point?

1reaction
imhoffdcommented, Mar 3, 2020

👋 Hey all, please see this comment and this wiki article for the latest on Ionic multi-app projects and Angular Monorepos. Using ng generate (not ionic start) with ng add @ionic/angular and ionic init provides a pretty smooth experience, as far as I can tell. Please let me know what you think. Monorepos are hard.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Multi-app Kiosk's Allowed desktop App Triggering Restrictions ...
We are using Microsoft Teams Desktop app in Multi-App kiosk mode configuration. We are encountering same error when we try to launch Teams...
Read more >
Multi-window support - Android Developers
Multi-window mode enables multiple apps to share the same screen simultaneously. Apps can be side by side or one above the other (split-screen...
Read more >
How to lock down Windows devices in multi-app kiosk mode?
Configure multi-app kiosk. Before associating the policy, you must create a local user account on your device and install the Universal Windows Platform...
Read more >
Problem running ClickOnce application in Windows 10 multi ...
Is there any other way of doing this for a ClickOnce application? The XML configuration file for the multi-app kiosk setup looks as...
Read more >
Trying to setup a multiapp kiosk for windows 10 bu...
The profile will load to the device but the status is "install pending" - it wont deploy. I have tried to troubleshoot the...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found