FacetWP – modify flatpickr options

mgibbs189

{{gist file=”test.js” lang=”javascript”}}
<script>
(function($) {
FWP.hooks.addFilter(‘facetwp/set_options/date_range’, function(flatpickr_opts, extras) {
flatpickr_opts[‘allowInput’] = true;
return flatpickr_opts;
});
})(jQuery);
</script>
{{/gist}}