Skip to content

Instantly share code, notes, and snippets.

@mikosd
mikosd / zoned.js
Created January 18, 2023 19:55 — forked from defunkt/zoned.js
Timezones in JavaScript, from http://errtheblog.com/posts/49-a-zoned-defense
var Timezone = {
set : function() {
var date = new Date();
date.setTime(date.getTime() + (1000*24*60*60*1000));
var expires = "; expires=" + date.toGMTString();
document.cookie = "timezone=" + (-date.getTimezoneOffset() * 60) + expires + "; path=/";
}
}

Unit1 PromiseDao Design Review

Overview

What's the problem with the way the PromiseDao currently works?

The PromiseDao only supports one source for promises: the Delivery Promise Service (DPS). We already need to get promises from another service, the Order Fulfillment Service (OFS), so this is a good time to make the design more flexible.

Use Cases