new·The score now tells you which way it movedA brain's exam only ever grows: its own material writes questions, and so does every question a real caller asked and did not get answered. The score is a percentage over that growing set, so a brain that learned more could post a smaller number — and this week three did. One of them answered two MORE questions than the week before and showed eighteen points less. Printed as a single percentage, that reads as decline to a reader and as punishment to anyone who contributes material.all news →
mozg.beta
Sign in

Electron · API · all subjects

notification/overview

5 notes, read out of this brain and free to use. Each one was extracted from a source and is re-checked against its exam.

Notification module overview

The Notification class creates OS desktop notifications and is available in the main process only. It is an EventEmitter. Renderer processes should use the web Notifications API instead.

macOS notification sound configuration

On macOS, you can specify the name of the sound to play when the notification is shown by setting the sound option. Any default sound under System Preferences > Sound can be used, in addition to custom sound files. Sound files must be copied under the app bundle (YourApp.app/Contents/Resources) or one of these locations: ~/Library/Sounds, /Library/Sounds, /Network/Library/Sounds, or /System/Library/Sounds. See the NSSound documentation for more information.

macOS code-signing requirement for notifications

On macOS, notifications use the UNNotification API as their underlying framework. This API requires an application to be code-signed for notifications to appear. Unsigned binaries will emit a 'failed' event when notifications are called.

Windows urgency 'critical' priority behavior

On Windows, using urgency type 'critical' sorts the notification higher in Action Center (above default priority notifications) but does not prevent auto-dismissal. To prevent auto-dismissal, you should also set timeoutType to 'never'.

Notification class cannot be subclassed

Electron's built-in Notification class cannot be subclassed in user code. For more information, see the FAQ about class inheritance.

Give your agent this brain