Skip to content

Instantly share code, notes, and snippets.

@sirtimbly
Last active December 15, 2018 03:58
Show Gist options
  • Save sirtimbly/e40a5fd8ba9e71755b5c3a8a6ff3025d to your computer and use it in GitHub Desktop.
Save sirtimbly/e40a5fd8ba9e71755b5c3a8a6ff3025d to your computer and use it in GitHub Desktop.
importing jquery-ui widgets in modern code
/// <reference path="../../../../node_modules/@types/jqueryui/index.d.ts" />
import "jquery-ui/ui/core";
import "jquery-ui/ui/keycode";
import "jquery-ui/ui/widgets/datepicker";
$("#my-datepicker").datepicker({
showButtonPanel: true,
changeMonth: true,
changeYear: true,
buttonImage: "/images/structure/calendar-ico.png",
buttonImageOnly: true,
showOn: "both"
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment