Merge pull request #14716 from jasperjn/master

Add options and render to clndr instance.
This commit is contained in:
anubmat
2017-02-23 11:07:27 -08:00
committed by GitHub
2 changed files with 14 additions and 0 deletions
+6
View File
@@ -71,6 +71,12 @@ const options: Clndr.ClndrOptions = {
const myCalendar = $('.parent-element').clndr(options);
myCalendar.options.constraints = {
startDate: '2017-12-22',
endDate: '2018-01-09'
};
myCalendar.render();
myCalendar
.forward()
.back()
+8
View File
@@ -13,6 +13,10 @@ export as namespace Clndr;
* The clndr instance
*/
export interface ClndrInstance {
/**
* Get clndr options
*/
options: ClndrOptions;
/**
* Go to the next month
*/
@@ -55,6 +59,10 @@ export interface ClndrInstance {
* calendar.
*/
removeEvents(filter: (event: any) => boolean): this;
/**
* Re-render of the calendar.
*/
render(): void;
/**
* Destroy the clndr instance. This will empty the DOM node containing the
* calendar.