Comments (11)
Hi everyone. Sorry for necro. I made it worked
I installed plugin by
cordova add https://github.com/jkhax0r/cordova-plugin-wakeuptimer.git
as htsnet said, there was json invalid error when i tried to use it. I edited java files a little to see error description. So i found what was wrong
skipOnAwake, skipOnRunning and startInBackground are the required fields in alarm option object! so i made it work with this code:
window.wakeuptimer.wakeup( function (a) {
console.log(a,"time success");
},
function (a) {
console.log(a,'timer set error');
},
// a list of alarms to set
{
alarms : [{
type : 'onetime',
skipOnAwake: false, // set timer, but skip launch if user is using the phone (screen is on)
skipOnRunning: false, // set wakeup timer, but skip launch if app is already running
startInBackground: false,
time : { hour : 22, minute : 26 },
extra : { message : 'json containing app-specific information to be posted when alarm triggers' },
message : 'Alarm has expired!'
}]
}
);
Hope it will be helpfull for someone
from cordova-plugin-wakeuptimer.
+1
from cordova-plugin-wakeuptimer.
+1
Still no fix for this issue?
from cordova-plugin-wakeuptimer.
I found another link: https://github.com/jkhax0r/cordova-plugin-wakeuptimer.git. With this, I could install normally. But... it does not work. When I try to set an alarm, I receive two messages error:
WakeupPlugin erros: invalid json
Invalid action
from cordova-plugin-wakeuptimer.
This plugin https://github.com/jkhax0r/cordova-plugin-wakeuptimer.gitIt It is not the same as wnyc?
use the same command to install cordova plugin add https://github.com/wnyc/cordova-plugin-wakeuptimer.git
from cordova-plugin-wakeuptimer.
Almost the same. The first was updated 8 months ago.
from cordova-plugin-wakeuptimer.
But if I install - cordova plugin add https://github.com/wnyc/cordova-plugin-wakeuptimer.git, I would not be installing the el jkhax0r?, or how do I install this https://github.com/jkhax0r/cordova-plugin-wakeuptimer.gitIt? Thanks!
from cordova-plugin-wakeuptimer.
Only the second one (https://github.com/jkhax0r/cordova-plugin-wakeuptimer.git). It is almost the same, but newer. I could install with no issues. The question is that it isn´t working yet. I receive 2 messages when trying to activate one alarm: WakeupPlugin error: invalid json; Invalid action.
from cordova-plugin-wakeuptimer.
cordova add https://github.com/jkhax0r/cordova-plugin-wakeuptimer.git adds this repository:
https://github.com/wnyc/cordova-plugin-wakeuptimer.git
from cordova-plugin-wakeuptimer.
Maybe. But I downloaded the zip file and installed locally. BUt, it doesn´t work to me yet. I receive a message "JSON Invalid". And I don´t know why.
from cordova-plugin-wakeuptimer.
Hi,I need your help
i have version cordova: 7.0.1
Ionic v 1
when trying to install the plugin not install:-> cordova plugin add https://github.com/wnyc/cordova-plugin-wakeuptimer.git
Error: Failed to fetch plugin https://github.com/wnyc/cordova-plugin-wakeuptimer.git via registry.
Probably this is either a connection problem, or plugin spec is incorrect.
Check your connection and plugin name/version/URL.
Error: cmd: Command failed with exit code 4294963228 Error output:
npm ERR! addLocal Could not install C:\Users\germa\AppData\Local\Temp\npm-6268-f4f54423\git-cache-eb611dc2\ae06fc686e7111f593d1e7489034ba77736fd5f2
npm ERR! Windows_NT 10.0.15063
npm ERR! argv "C:\Program Files\nodejs\node.exe" "C:\Program Files\nodejs\node_modules\npm\bin\npm-cli.js" "install" "https://github.com/wnyc/cordova-plugin-wakeuptimer.git" "--save"
npm ERR! node v6.9.2
npm ERR! npm v3.10.9
npm ERR! code EISDIR
npm ERR! errno -4068
npm ERR! syscall readnpm ERR! eisdir EISDIR: illegal operation on a directory, read
npm ERR! eisdir This is most likely not a problem with npm itself
npm ERR! eisdir and is related to npm not being able to find a package.json in
npm ERR! eisdir a package you are trying to install.npm ERR! Please include the following file with any support request:
npm ERR! C:~~\node_modules\npm-debug.log
How did you tackle this issue ? Were you able to resolve it by above help i.e installation of alternate plugin ?
from cordova-plugin-wakeuptimer.
Related Issues (20)
- Phonegap Build compatibility HOT 3
- How to cancel the alarm clock HOT 5
- delete HOT 3
- I don't receive successCallback, console logs on iOS 9 iphone. HOT 1
- wakeup time not accurate? HOT 2
- how to set alarm date and time HOT 6
- bring the app to foreground (IOS) HOT 1
- Using ionic2 HOT 5
- How to set sound file?
- I can't find any code about this plugin in the SimpleAlarmExample HOT 3
- Is it possible to load this plugin in the background, and launch normally from App icon
- how to execute a specific function when alarm wake up ?
- Getting error while installing plugin
- Archive import has failed.
- Repository not maintained? Any good tutorial? HOT 3
- Function: Callback always returns unhandled type HOT 1
- Plugin waking up the app too late
- cannot install plugin HOT 1
- Not working on screen lock HOT 6
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from cordova-plugin-wakeuptimer.