Skip to content

Instantly share code, notes, and snippets.

View Thanood's full-sized avatar

Daniel Bendel Thanood

  • Cologne, Germany
View GitHub Profile
@Thanood
Thanood / flatpickr.d.ts
Last active October 17, 2016 13:10
Flatpicker custom attribute
// https://github.com/Microsoft/TypeScript/issues/5073
declare module 'flatpickr' {
class Flatpickr {
constructor(element: Element, options?: any);
destroy();
}
namespace Flatpickr {}
export = Flatpickr;
}
jQueryUiAdapter.prototype.openDialog = function (settings) {
var dfd = system.defer();
var defaultSettings = {
appendTo: 'body',
dialogHost: 'dialogHost',
dialogPromise: dfd,
title: '',
cssClass: '',
viewmodel: null,
autoOpen: false,
@cuppster
cuppster / 1.cs
Created September 3, 2012 18:39
Promises for C# using Generics
/*
modified from original source: https://bitbucket.org/mattkotsenas/c-promises/overview
*/
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace Promises