Notes - IBM Carbon Components for Svelte

IBM Carbon Components - Svelte

DatePicker

<script>
  import { DatePicker, DatePickerInput } from "carbon-components-svelte";
</script>

<DatePicker datePickerType="single" dateFormat="m/d/Y">
  <DatePickerInput labelText="Schedule a meeting" placeholder="mm/dd/yyyy" />
</DatePicker>
  • When set datePickerType to single or range, the calendar will show out
  • dateFormat use only one character for day, month and year. e.g. March 15, 2021 - m/d/Y(03/15/2021) or Y-m-d(2021-03-15)

Reference

updatedupdated2022-01-162022-01-16