You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/native-faq.md
+11-71Lines changed: 11 additions & 71 deletions
Original file line number
Diff line number
Diff line change
@@ -3,83 +3,23 @@ sidebar_label: FAQ
3
3
slug: /native/faq
4
4
---
5
5
6
-
# Ionic Native FAQ
6
+
# Frequently Asked Question
7
7
8
-
## Cordova Management Tips
8
+
## What is Capacitor?
9
9
10
-
**1) Use the [Ionic CLI](cli.md)to add/update/delete plugins.**
10
+
Capacitor a native runtime built by the Ionic team that offers web developers the ability to deploy their web apps to a native device. Capacitor also exposing native device capabilities through JavaScript so developers could access features like native location services, filesystem access, or notifications as if they are interacting with any other JavaScript library.
11
11
12
-
Instead of directly editing `config.xml` and `package.json`. Use `ionic` in front of Cordova commands for a better experience and additional functionality (`ionic cordova build ios` instead of `cordova build ios`).
12
+
## Permission Issues
13
13
14
-
**2) Upgrade plugins by removing, then re-adding them.**
14
+
If you're using a plugin, it may require adding additional permissions to your native project after you install the plugin. For instance, the Capacitor Camera plugin requires the following permission for iOS:
**4) Restore Cordova in an existing Ionic project**
30
-
31
-
Useful when adding new developers to a project. `ionic cordova prepare` restores platforms and plugins from `package.json` and `config.xml`. The version to be installed is taken from `package.json` or `config.xml`, if found in those files. In case of conflicts, `package.json` is given precedence over `config.xml`.
32
-
33
-
**5) Troubleshoot Cordova issues with Ionic CLI commands**
34
-
35
-
-`ionic doctor list`: Detects [common issues](cli/commands/doctor-list.md) and suggests steps to fix them
36
-
-`ionic repair`: Remove, then [regenerate](cli/commands/repair.md) all dependencies
37
-
38
-
## Understanding Version Numbers
39
-
40
-
For any given Ionic Native plugin, the Ionic Native (TypeScript code) and Cordova (native code) version numbers will not match. The Ionic Native version number is found in `package.json`:
41
-
42
-
```json
43
-
"@awesome-cordova-plugins/camera": "^5.3.0",
44
-
```
45
-
46
-
The Cordova plugin version number is found in both `package.json` and `config.xml`:
When checking for new native functionality or bug fixes, look for new versions on the Cordova plugin GitHub page itself (here's the [Camera one](https://github.com/apache/cordova-plugin-camera), for example).
57
-
58
-
To check for new Ionic Native releases (may include exposing methods recently added by the Cordova plugin, etc.), see [here](https://github.com/ionic-team/ionic-native/releases).
59
-
60
-
## Troubleshooting Failed Builds
61
-
62
-
Research the build error(s) by checking out these resources:
63
-
64
-
- Google & [StackOverflow](https://stackoverflow.com): Many issues are documented online
65
-
- Ask the [Ionic Community Ionic Forum](https://forum.ionicframework.com) (see the Ionic Native category)
66
-
- See the Ionic Customer Success [Knowledge Base](https://ionic.zendesk.com)
67
-
68
-
### Cordova Plugin Conflicts
69
-
70
-
Plugins can conflict with each other when they share the same underlying native dependencies or when more than one plugin tries to access the same native code at once. For example, common libraries like the Google Play Services version (Google Maps is using GPS v24.2 but Firebase wants GPS v27.1). Keeping these plugins updated regularly can help with this.
71
-
72
-
Another tip is to ensure that your app uses only one plugin per specific feature/functionality (example: Push Notifications).
73
-
74
-
## Recommended Upgrade Strategy
75
-
76
-
The most Ionic stable apps are routinely updated, especially at the native layer. Keeping native plugins up to date ensures your project has the latest security fixes, new features, and improved performance.
77
-
78
-
Update your project's plugins one at a time, ideally in separate code branches. This reduces the surface area that issues can arise from - if you update everything in your project at once, it's sometimes hard to tell where the problem stems from.
79
-
80
-
### When should I update?
81
-
82
-
- When a new feature/bug is released: Run `npm outdated` to see a list of available updates.
83
-
- When new major versions are released: Official blogs, such as the [Cordova blog](https://cordova.apache.org/blog/) and [Ionic blog](https://ionicframework.com/blog/), will publish announcements and news.
84
-
- Evaluate the nature of the update: is it a shiny new feature or critical security fix?
85
-
- Timing: Where does it fit in against your team's project goals?
25
+
If for some reason the plugin does not behave in a way that is unexpected, please [open an issue on our github repo](https://github.com/ionic-team/capacitor-plugins)! Providing a clear issue report along with a reproduction can help get your issue resolved.
0 commit comments