aboutsummaryrefslogtreecommitdiff
path: root/src/lib/notification-i18n-loader.js
diff options
context:
space:
mode:
authorlain <lain@soykaf.club>2020-06-13 11:53:16 +0200
committerlain <lain@soykaf.club>2020-06-13 11:53:16 +0200
commit1e57adf6d4a46ab5be677bba7ae3c7f0ba0fc520 (patch)
treeb614d32802dbccb5ecce1d6658a2d68d6fbae5d1 /src/lib/notification-i18n-loader.js
parent9bfb3754c1bc0d1033afda97f2884e721d1ab3d8 (diff)
Linting + docs
Diffstat (limited to 'src/lib/notification-i18n-loader.js')
-rw-r--r--src/lib/notification-i18n-loader.js7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/lib/notification-i18n-loader.js b/src/lib/notification-i18n-loader.js
index a61755c8..71f9156a 100644
--- a/src/lib/notification-i18n-loader.js
+++ b/src/lib/notification-i18n-loader.js
@@ -1,5 +1,8 @@
-// This somewhat mysterious module
-module.exports = function(source) {
+// This somewhat mysterious module will load a json string
+// and then extract only the 'notifications' part. This is
+// meant to be used to load the partial i18n we need for
+// the service worker.
+module.exports = function (source) {
var object = JSON.parse(source)
var smol = {
notifications: object.notifications || {}