-
Notifications
You must be signed in to change notification settings - Fork 990
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
refactor!: do not copy JS lib to platform project #1203
Conversation
df0cd6b
to
9099962
Compare
Codecov Report
@@ Coverage Diff @@
## master #1203 +/- ##
==========================================
+ Coverage 75.09% 78.53% +3.44%
==========================================
Files 13 15 +2
Lines 1658 1761 +103
==========================================
+ Hits 1245 1383 +138
+ Misses 413 378 -35
Continue to review full report at Codecov.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🎉
Co-authored-by: Raphael von der Grün <[email protected]>
@erisu Hi! Could you please tell me how to change from old method of getting /cordova/lib/projectFile.js to new one? |
the lib files remain inside
A hacky way getting access to Note the old way that you posted might still be required if you intend to support cordova-ios 6 and earlier. Here is an example of how this plugin does it to support both versions. |
@breautek Thanks! |
Motivation and Context
The goal of this PR is to remove the pratice of copying the entire JS lib of
cordova-ios
into each generated platform project.Description
node_modules
) to platform projectbin/lib/create.js
tolib/
bin/templates/scripts/cordova/lib
tolib/
bin/templates/scripts/cordova/Api.js
tolib/
After these changes, the
cordova/
folder of a generated project only contains the bare minimum to maintain compatibility with existing cordova CLI versions (plusdefaults.xml
which IMHO should be moved in another PR). All of the remaining JS files in that folder require their dependencies via thecordova-ios
module, so that needs to be resolvable somehow (which is the case for a platform project generated by the regular CLI workflow).Testing