liplylie / react-native-simple-alarm Goto Github PK
View Code? Open in Web Editor NEWAlarm clock functionality for react native ios and android using react-native-push-notification and react-native-community/async-storage
Alarm clock functionality for react native ios and android using react-native-push-notification and react-native-community/async-storage
how do i remove the modal view?
Thank's
I have the next error when i try to delete a alarm by id:
Error: Please enter an alarm id
but i confirmed that i am sending the id correctly.
Hello,
I just copied the code from the example, tried to run on fresh new project,
I get 'Native module cannot be null' error in iOS.
I guess it is the createAlarm function that is causing the problem since when I comment it out, error disappears
Great app! I found it while I was searching for an alarm clock that can be combined with home automation. Seems like there is nothing like that. So I wanted to make the suggestion here:
It would be awesome to implement a feature to trigger a smart home switch or to trigger an API request.
The idea is to set an alarm via an alarm clock to trigger a task once the alarm goes off.
Any chance you could implement a feature like that? ๐
Thanks!
Hi! First, thank you for this library!
Last year I worked on a project with the need to create alarms, but I found this limitation: https://developer.apple.com/documentation/uikit/uilocalnotification
An app can have only a limited number of scheduled notifications; the system keeps the soonest-firing 64 notifications (with automatically rescheduled notifications counting as a single notification) and discards the rest.
How was this handled here in this library?
The async storage dependancy has moved to another organisation, see there:
https://www.npmjs.com/package/@react-native-community/async-storage
Hi :)
I'm making an alarm app, but the alarm rings even in silent mode?
In this library you are using, there is no way to sound an alarm in silent mode. issue
Is this possible? I haven't installed this library yet, but if it works, I will install it and use it
Hi, I'm getting this error when trying to run.
Unable to resolve "moment" from "node_modules\react-native-simple-alarm\src\helpers\activateAlarm.js"
Any idea how I can rectify this?
Thanks
Hi,
I am trying to build the example project but having the errors below
Wondering if someone could please help
alexchudnovsky:example/ $ npm install [18:36:54]
npm ERR! code ERESOLVE
npm ERR! ERESOLVE unable to resolve dependency tree
npm ERR!
npm ERR! While resolving: [email protected]
npm ERR! Found: [email protected]
npm ERR! node_modules/react
npm ERR! react@"16.11.0" from the root project
npm ERR! peer react@"^16.8" from @react-native-community/[email protected]
npm ERR! node_modules/@react-native-community/async-storage
npm ERR! @react-native-community/async-storage@"1.12.1" from the root project
npm ERR!
npm ERR! Could not resolve dependency:
npm ERR! peer react@"16.13.1" from [email protected]
npm ERR! node_modules/react-native
npm ERR! react-native@"0.63.4" from the root project
npm ERR! peer react-native@">=0.59" from @react-native-community/[email protected]
npm ERR! node_modules/@react-native-community/async-storage
npm ERR! @react-native-community/async-storage@"1.12.1" from the root project
npm ERR!
npm ERR! Fix the upstream dependency conflict, or retry
npm ERR! this command with --force, or --legacy-peer-deps
npm ERR! to accept an incorrect (and potentially broken) dependency resolution.
Many thanks,
Alex
i wanted to know if the alarm in android is just a single ringtone
Hello,
I tried to implement this library into my project for sending scheduled alerts. but I found out some problems.
On IOS: The alert is sent every minute (not at the date and snooze expected).
On Android: I see in the log that alert is created but I received nothing (no alerts, no push notifications). I tried to replicate the same configurations as in example app but still not work.
const dateForAlert = moment() .add(3, 'minutes') .startOf('minute') .format(); const resAlarm = await createAlarm({ active: true, date: dateForAlert, allowWhileIdle: true, message:
${loadID} ${I18n.t('alarmMessage')}, // snooze: SNOOZE_MINUTES, snooze: 2, userInfo: { tripID, loadID, }, });
Moreover on Android, I always have the error in debug mode and in release apk mode, the app crashed. Here is the error I can find in the log.
Error: EISDIR: illegal operation on a directory, read at Object.readSync (fs.js:592:3) at tryReadSync (fs.js:366:20) at Object.readFileSync (fs.js:403:19) at UnableToResolveError.buildCodeFrameMessage (/home/brady/obs-websocket-app/node_modules/metro/src/node-haste/DependencyGraph/ModuleResolution.js:347:17) at new UnableToResolveError (/home/brady/obs-websocket-app/node_modules/metro/src/node-haste/DependencyGraph/ModuleResolution.js:333:35) at ModuleResolver.resolveDependency (/home/brady/obs-websocket-app/node_modules/metro/src/node-haste/DependencyGraph/ModuleResolution.js:211:15) at DependencyGraph.resolveDependency (/home/brady/obs-websocket-app/node_modules/metro/src/node-haste/DependencyGraph.js:413:43) at /home/brady/obs-websocket-app/node_modules/metro/src/lib/transformHelpers.js:317:42 at /home/brady/obs-websocket-app/node_modules/metro/src/Server.js:1471:14 at Generator.next (<anonymous>)
Hi there, i got this error when i try to run deleteAllAlarms() in android emulator:
[Sat Jul 18 2020 12:13:43.453] LOG [TypeError: storage.forEach is not a function. (In 'storage.forEach(function (_ref) {
var oid = _ref.oid;
cancelAlarmById(oid);
})', 'storage.forEach' is undefined)]
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.