woocommerce/plugins/woocommerce-admin/docs/components/packages/date.md

532 B

Date (component)

Use the Date component to display accessible dates or times.

Props

date

  • Required
  • Type: String
  • Default: null

Date to use in the component.

machineFormat

  • Type: String
  • Default: 'Y-m-d H:i:s'

Date format used in the datetime prop of the time element.

screenReaderFormat

  • Type: String
  • Default: 'F j, Y'

Date format used for screen readers.

visibleFormat

  • Type: String
  • Default: 'Y-m-d'

Date format displayed in the page.