svelte-flatpickr
- Svelte component wrapper for the flatpickr datetime picker library
- Designed specifically for Svelte framework integration
- Provides Svelte bindings and event handling for flatpickr functionality
Key Features:
- Two-way binding for selected dates (
value
) and formatted strings (formattedValue
) - Supports all standard flatpickr configuration options
- Exposes flatpickr events through Svelte event handlers
- Allows using external/custom elements as the picker input (following flatpickr's wrap pattern)
Version Compatibility:
- v3.x.x for Svelte 3
- v1.x.x for Svelte 2
- v0.x.x for Svelte 1
Usage Notes:
- Requires importing flatpickr's CSS separately
- Supports both flatpickr's native hooks and Svelte event listeners
- Can access underlying flatpickr instance and input element through bindings
- Includes example implementation in repository's test directory
The component maintains all flatpickr functionality while providing a Svelte-native interface through props, bindings, and events.
flatpickrsveltehacktoberfest
Author
Featured Stories
No featured articles here. Navigate to an article, then pick the Feature on menu button