charnekin / api Goto Github PK
View Code? Open in Web Editor NEWJS API for cordova apps
JS API for cordova apps
The current method for checking if the app is running on mobile does not work if you are running in the ripple emulator, the following code will add check for the emulator and assume mobile,
var cordovaLoadIfMobile = function () {
var isMobile = function () {
var protocol = location.protocol;
if ( protocol.indexOf("http:") === 0 ){
return false;
}else{
return true;
}
};
var emulated = window.tinyHippos != undefined;
if (isMobile() || emulated) {
require([
'mobile'
], function () {
Mobile.load();
});
}};
Sorry for a bit of crossposting here as I'm posting this on 2 githubs, primarily as this one has little to no traction. I am using the charnekin code in conjunction with the custome url protocol mentioned above and when launched from an URL I just get a blank screen, nothing else. I'm trying to locate the issue but it's proving to be most difficult.
Where would I start? I can use chrome inspect with the emulator but it doesn't show any errors. If I place my handler in index.html along with an alert when the page loads, the alert is displayed but the handler is not invoked.
Hi there,
I'm trying to remove the secondary language from the code so that only english exists in my first version, I can remove all the string literals fine, but when I remove the language from the en.languages array I get an out of bounds error, it still attempts to look for a language at index 1 of rhe array.
Where is it getting the language count from and how do i change it?
Many thanks in advance.
Hi there,
Is it possible to add stuff to the head element of a page? Such as optional javascript that i only want loaded on certain modules. I'm kind of guessing it's not as it's a single page that's rendered once only.
I'm getting by with just including my script for all pages for the moment but if it's possible to optimise it in this way that would be great.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.