Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fail to find where to set the first day of week in date-picker component. #1055

Closed
tbwork opened this issue Dec 21, 2020 · 7 comments
Closed
Assignees
Labels
Project::Documentation Improvements or additions to documentation

Comments

@tbwork
Copy link

tbwork commented Dec 21, 2020

The options is deprecated, and nothing more is present in the document to set the firstDayOfWeek option.

@zazzaz
Copy link
Contributor

zazzaz commented Dec 21, 2020

We will update the doc soon.

Ref #162 (comment)

remove first-day-of-week, use Day.js locale instead,

All you have to do is to import Day.js locale like

import 'dayjs/locale/en'
dayjs.locale('en')

@zazzaz zazzaz self-assigned this Dec 21, 2020
@zazzaz zazzaz added the Project::Documentation Improvements or additions to documentation label Dec 21, 2020
@tbwork
Copy link
Author

tbwork commented Dec 21, 2020

@zazzaz Would you like to give out more details? How to set the first day of week by dayjs?

@zazzaz
Copy link
Contributor

zazzaz commented Dec 21, 2020

You can check af Afrikaans locale as a reference

https://github.com/iamkun/dayjs/blob/dev/src/locale/af.js#L8

weekStart: 1,

That is to say, the first day of the week of this locale is Monday.

@tbwork
Copy link
Author

tbwork commented Dec 21, 2020

Thanks very much! Hope this can be updated to the document!~

@zazzaz
Copy link
Contributor

zazzaz commented Dec 21, 2020

You’re most welcome. And the doc will be updated soon

@zazzaz
Copy link
Contributor

zazzaz commented Dec 29, 2020

@zazzaz zazzaz closed this as completed Dec 29, 2020
@pk8848597
Copy link

doc updated https://element-plus.org/#/en-US/component/i18n#set-day.js-locale

Excuse me, this link can't be accessed normally

@github-actions github-actions bot locked and limited conversation to collaborators Dec 13, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Project::Documentation Improvements or additions to documentation
Projects
None yet
Development

No branches or pull requests

3 participants