From 19a75797beac86394dc7bc6c65f9acc7c4183947 Mon Sep 17 00:00:00 2001 From: Sayan Pal Date: Fri, 5 Aug 2016 15:32:33 +0200 Subject: [PATCH] Added missing function config() to Pikaday class This function was missing from the type definitions that can be used at runtime to change/extend configuration options. Can be very useful to change various configurations, such as i18n (culture information), format, firstDay etc. on runtime. --- pikaday/pikaday.d.ts | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/pikaday/pikaday.d.ts b/pikaday/pikaday.d.ts index 3e4f80df9a..913ea69613 100644 --- a/pikaday/pikaday.d.ts +++ b/pikaday/pikaday.d.ts @@ -10,6 +10,14 @@ declare class Pikaday { constructor(options: Pikaday.PikadayOptions); + /** + * Extends the existing configuration options for Pikaday object with the options provided. + * Can be used to change/extend the configurations on runtime. + * @param options full/partial configuration options. + * @returns {} extended configurations. + */ + config(options: Pikaday.PikadayOptions): Pikaday.PikadayOptions; + /** * Returns the selected date in a string format. If Moment.js exists * (recommended) then Pikaday can return any format that Moment