logo

pleroma-fe

My custom branche(s) on git.pleroma.social/pleroma/pleroma-fe git clone https://anongit.hacktivis.me/git/pleroma-fe.git/

notification-i18n-loader.js (371B)


  1. // This somewhat mysterious module will load a json string
  2. // and then extract only the 'notifications' part. This is
  3. // meant to be used to load the partial i18n we need for
  4. // the service worker.
  5. module.exports = function (source) {
  6. const object = JSON.parse(source)
  7. const smol = {
  8. notifications: object.notifications || {}
  9. }
  10. return JSON.stringify(smol)
  11. }