未验证 提交 b6fd41b3 编写于 作者: O openharmony_ci 提交者: Gitee

!7480 修改i18n和intl代码示例

Merge pull request !7480 from sunyaozu/master
...@@ -698,7 +698,8 @@ static getLocationName(number: string, locale: string): string ...@@ -698,7 +698,8 @@ static getLocationName(number: string, locale: string): string
**示例:** **示例:**
```js ```js
var location = i18n.PhoneNumberFormat.getLocationName('15812312345', 'zh-CN'); var phonenumberfmt = new i18n.PhoneNumberFormat("CN");
phonenumberfmt.getLocationName("15812312345", "zh-CN");
``` ```
......
...@@ -540,7 +540,7 @@ constructor(locale: string | Array<string>, options?: PluralRulesOptions) ...@@ -540,7 +540,7 @@ constructor(locale: string | Array<string>, options?: PluralRulesOptions)
**示例:** **示例:**
```js ```js
var pluralRules= new Intl.PluraRules("zh-CN", {"localeMatcher": "lookup", "type": "cardinal"}); var pluralRules= new Intl.PluralRules("zh-CN", {"localeMatcher": "lookup", "type": "cardinal"});
``` ```
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册