When developing open web apps, a lot of what you'll want to do involves controlling the display or transmission of data to the user in some way. This can include giving the user notifications of different kinds to let them know when some kind of event has occured related to the app's running, and controlling various aspects of the user interface behaviour The below articles follow this general themes.
- Detecting when to notify users
- Most of us are familiar with the concept of event handlers, and how we can use them to provide scripted responses to events that occur in the program. But there is a lot more to think about when working out how to determine when a certain set of conditions is true, from the point of view of a user's environment. This article shares some thoughts on the subject.
- Checking when a deadline is due
- In this article we look at a complex example involving checking the current time and date against a deadline stored in a database.
- Notifying users via the Notification and Vibration APIs
- Once you have successfully detected the occurence of an event, the next step is respond to it. One of the most basic responses you can give is to provide the user with a notification to let them know something useful, and the Notification and Vibration APIs provide immediate simple and effective system-wide feedback. This article explains how to use both of them in context.
- Using alarms to notify users
- The Alarm API is another tool at your disposal for providing a user with a system notification, providing a more simplistic workflow for automatically setting notification deadlines and checking when they are due, rather than having to do all this manually via some kind of regular timer and complex checking function like we did in the previous article. This article shows how it's done.
User interface control
- Using the full screen: Full screen API explained
- This article provides a quickfire guide on using the Full Screen API to enable full screen app viewing.
- Pointer Lock
- Screen orientation
We need articles covering interesting uses of the above, in the context of Open Web Apps. Demos and ideas welcome!