ademilter / ademilter/Frame

Notifications shouldn't be inside of the Vue app

Abierto
#21 1 comentario 0 reacciones 0 asignados Ver en GitHub
Lenguaje dominante
Vue
Estrellas
91
Forks
11
Métricas de merge de PR
Sin PR fusionados en 30 d

Descripción

Currently notification code lives under tab content side inside Vue app. Because of that, if there is an event in one hour, I'm getting the same notification whenever I open a new tab. And this is quite disturbing. I would want it to see once, not everytime I open a new tab. I think we should create a [background script][1] for the extension and check the events there every minute. (And we should use `chrome.notifications.create` inside the backround script since the Notification API won't work inside that script.)

We can communicate between background script and Vue app with that API call: `chrome.extension.getBackgroundPage()`.

We can create a background script that checks the events every minute in background script, there is a step by step walk-through here: https://developer.chrome.com/apps/app_codelab_alarms (The only difference, we shouldn't use `chrome.app.runtime.onLaunched.addListener` and use `chrome.extension.getBackgroundPage()` to call from Vue app)

**I can mentor someone who wants to work on that issue. You can leave a comment here if you want to work on that. I can provide additional information.**

[1]: https://developer.chrome.com/extensions/background_pages

Guía de contribución

No hay ninguna guía de contribución indexada para este repositorio

Evaluación

Este issue todavía no se ha evaluado.

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.