alalamav opened a new issue #106:
URL: https://github.com/apache/cordova-osx/issues/106
# Bug Report
## Problem
### What is expected to happen?
cordova-osx should restore plugins from `package.json` when running `cordova
platform add osx`. The plugins' native and JS code should run before the
`deviceready` event is fired.
### What does actually happen?
Plugins declared in `package.json` are successfully added to the native
macOS (Xcode) project, but their code is not run. As a result, the WebView is
not able to access exported definitions (i.e. window.device for
cordova-plugin-device).
## Information
- When restoring plugins from `package.json`:
- the last installed plugin overrides existing configurations in
`platforms/osx/www/cordova_plugins.js`
- `platforms/osx/cordova-macos-test/config.xml` and
`platforms/osx/osx.json` are missing plugin declarations.
- Manually removing and adding plugins successfully configures them to run.
- Note that this issue does not occurr in [email protected] (or
cordova-ios@6.*).
### Command or Code
Please see
[alalamav/cordova-macos-test](https://github.com/alalamav/cordova-macos-test)
for a detailed description of the problem and reproduction steps.
### Environment, Platform, Device
macOS
### Version information
- [email protected]
- [email protected]
- macOS 10.15.3
- Xcode 11.6
## Checklist
- [x] I searched for existing GitHub issues
- [x] I updated all Cordova tooling to most recent version
- [x] I included all the necessary information above
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]