Reputation: 124
I have build an android
app with help of quasar
and cordova
.
Now I want to add print function that is actually device specific (e.g. mpos device).
I have uploaded the source code of native android
project that i want to use in my cordova project repo of android source code.
I want to call printText
function into cordova-plugin
from native android
link to printText function
something similar like below:
exports.print= function (arg0, success, error) {
exec(success, error, 'PrintDevActivity', 'printText', [arg0]);
}
I need help in these two things:
how many files i need to copy from above repo of android project to my cordova plugin
what changes i need to do in cordova plugin plugin.xml
so it will work.
I am confused , should i need to copy only .java
files or also gradle etc.
This is my plugin.xml
file of cordova plugin
Any help or suggestion will highly appreciated.
Thank you
Upvotes: 0
Views: 722
Reputation: 26
As per your question, I think you need to build cordova plugin
for any android sdk
.
Please check below link, i think this is have lot of information about building cordova
plugin with any existing sdk
or code.
building-a-cordova-plugin-for-your-native-sdk
I hope this will help you. Thanks
Upvotes: 1
Reputation: 84
follow this guide Upgrading Android Apache Cordova and it'll help you in part 1 of updating your config.xml file. Their Documentation is pretty simple to follow along.
Upvotes: 0