Update content

This commit is contained in:
gouguoyin 2024-11-25 02:20:19 +08:00
parent d4ca9b25e7
commit 60efedaf66
3 changed files with 3 additions and 3 deletions

View File

@ -54,7 +54,7 @@ go mod edit -replace github.com/golang-module/carbon/v2=github.com/dromara/carbo
```go
carbon.SetDefault(carbon.Default{
Layout: carbon.DateTimeLayout,
Timezone: carbon.PRC,
Timezone: carbon.UTC,
WeekStartsAt: carbon.Sunday,
Locale: "zh-CN", // 取值范围lang 目录下翻译文件名,不包含文件后缀
})

View File

@ -56,7 +56,7 @@ go mod edit -replace github.com/golang-module/carbon/v2=github.com/dromara/carbo
```go
carbon.SetDefault(carbon.Default{
Layout: carbon.DateTimeLayout,
Timezone: carbon.PRC,
Timezone: carbon.UTC,
WeekStartsAt: carbon.Sunday,
Locale: "jp", // 値の範囲: langディレクトリ下の翻訳ファイル名でファイル拡張子は含まない
})

View File

@ -55,7 +55,7 @@ go mod edit -replace github.com/golang-module/carbon/v2=github.com/dromara/carbo
```go
carbon.SetDefault(carbon.Default{
Layout: carbon.DateTimeLayout,
Timezone: carbon.Local,
Timezone: carbon.UTC,
WeekStartsAt: carbon.Sunday,
Locale: "en", // value range: translate file name in the lang directory, excluding file suffix
})