Security News
Weekly Downloads Now Available in npm Package Search Results
Socket's package search now displays weekly downloads for npm packages, helping developers quickly assess popularity and make more informed decisions.
svelte-day-picker
Advanced tools
A solid calendar component for Svelte and drop-in replacement for React Day Picker. Uses the Temporal API to handle dates, although it is also backwards-compatible with Date
.
yarn add svelte-day-picker
# OR
npm install svelte-day-picker
<script>
import DayPicker, { Mode } from 'svelte-day-picker';
let selected;
$: first = selected?.at(0);
$: last = selected?.at(-1);
</script>
<span>From {first?.toLocaleString()} to {last?.toLocaleString()}</span>
<DayPicker numberOfMonths={2} mode={Mode.Range} bind:selected={selected} />
<DayPicker />
string | Intl.Locale
string | Temporal.CalendarProtocol
'gregory'
'gregory'
or 'iso8601'
(which are almost the same), but other calendar identifiers include 'buddhist'
, 'chinese'
, 'hebrew'
, 'islamic'
.string
DayOfWeek
DayOfWeek[]
number
(positive integer)1
Date | Temporal.PlainYearMonthLike
Date | Temporal.PlainYearMonthLike
bind:
propery controling the current month.boolean
false
Density
Density.Sparse
Mode
Mode.Single
Temporal.PlainDate[]
[]
bind:
property containing all the selected dates.{ from: Temporal.PlainDate, to: Temporal.PlainDate } | undefined
undefined
bind:
property containing the selected range, if the mode is Mode.Range
.Matcher[] | Matcher
[]
Matcher[] | Matcher
[]
Date | Temporal.PlainDate
new Date()
(the current date)<MonthTitle />
<DayHeading />
<Day />
FAQs
A solid calendar component for Svelte
We found that svelte-day-picker demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 0 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Socket's package search now displays weekly downloads for npm packages, helping developers quickly assess popularity and make more informed decisions.
Security News
A Stanford study reveals 9.5% of engineers contribute almost nothing, costing tech $90B annually, with remote work fueling the rise of "ghost engineers."
Research
Security News
Socket’s threat research team has detected six malicious npm packages typosquatting popular libraries to insert SSH backdoors.