capacitor-plugins icon indicating copy to clipboard operation
capacitor-plugins copied to clipboard

feat: Add catalyst/desktop mode info to Device.getInfo

Open piotrblasiak opened this issue 4 years ago • 2 comments

Feature Request

Describe the Feature Request

In xcode you can now target your app for desktop by using catalyst. Device.getInfo currently returns the model info but that is currently set to "iPad" for catalyst, and no other way of detecting if the app is being run on desktop.

Platform Support Requested

  • [ ] Android
  • [x] iOS
  • [ ] Electron
  • [ ] Web

Describe Preferred Solution

I suggest adding a "desktop" field or similar. It is easy to do following this article (I've tried and verified it): https://www.hackingwithswift.com/example-code/catalyst/how-to-detect-your-ios-app-is-running-on-macos-catalyst

Describe Alternatives

There are no other good ways of doing this that I know of.

piotrblasiak avatar Apr 18 '20 07:04 piotrblasiak

Issues tagged with feature request are closed but tracked for👍 reactions to gauge interest.

jcesarmobile avatar Apr 20 '20 09:04 jcesarmobile

Possible Solution to check whether Catalyst:

https://github.com/ionic-team/capacitor/issues/7239#issuecomment-1936082650

folsze avatar Feb 10 '24 08:02 folsze