NotificationFactories.js 817 B

123456789101112131415161718192021
  1. "use strict";
  2. Object.defineProperty(exports, "__esModule", { value: true });
  3. exports.createNotification = exports.nextNotification = exports.errorNotification = exports.COMPLETE_NOTIFICATION = void 0;
  4. exports.COMPLETE_NOTIFICATION = (function () { return createNotification('C', undefined, undefined); })();
  5. function errorNotification(error) {
  6. return createNotification('E', undefined, error);
  7. }
  8. exports.errorNotification = errorNotification;
  9. function nextNotification(value) {
  10. return createNotification('N', value, undefined);
  11. }
  12. exports.nextNotification = nextNotification;
  13. function createNotification(kind, value, error) {
  14. return {
  15. kind: kind,
  16. value: value,
  17. error: error,
  18. };
  19. }
  20. exports.createNotification = createNotification;
  21. //# sourceMappingURL=NotificationFactories.js.map