Yurba Docs
Yurba Documentation

Get started

Accounts

Apps

Users

Relationships

Dialogs (Messages)

Tracks (MuseBase)

Photos

Posts

Comments

Safety

Other

Yurba CDN (cdn.yurba.one)

For Desktop Developers

METHOD createNotification

Allows you to create custom notifications on behalf of the application

app.createNotification(string NameID)

METHODS

prepare(object NotificationPrepare { icon: string IconID, title: string Title, content: string Content }) show(string NameID)

EXAMPLE

const notify = app.createNotification("myNotification") notify.prepare({ "icon": "yurbadev", "title": "Example", "content": "Hello world!" }); notify.show()

In this code we create a variable that contains the unique name of the identifier, then together with this variable we use the prepare() method to customize the notification: we put an icon, a title and the text that will be visible under the title, and then we simply show this notification: