(win: WindowCapacitor)
| 34 | } |
| 35 | |
| 36 | export const getPlatformId = (win: WindowCapacitor): 'android' | 'ios' | 'web' => { |
| 37 | if (win?.androidBridge) { |
| 38 | return 'android'; |
| 39 | } else if (win?.webkit?.messageHandlers?.bridge) { |
| 40 | return 'ios'; |
| 41 | } else { |
| 42 | return 'web'; |
| 43 | } |
| 44 | }; |