Skip to content

Commit

Permalink
Add charset="UTF-8"
Browse files Browse the repository at this point in the history
  • Loading branch information
breezewish committed May 24, 2016
1 parent 427cc40 commit 34d6c61
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,13 +39,15 @@ pinyinlite('增长');
### 浏览器

```html
<script src="dist/pinyinlite.min.js"></script>
<script charset="UTF-8" src="dist/pinyinlite.min.js"></script>
<script>
console.log(pinyinlite('世界你好'));
// => [ [ 'shi' ], [ 'jie' ], [ 'ni' ], [ 'hao' ]]
</script>
```

引用脚本时请务必保留 `charset="UTF-8"`,否则在部分浏览器中会由于编码识别错误而产生问题。

## 选项

```js
Expand Down

0 comments on commit 34d6c61

Please sign in to comment.