docs: zh-cn translation for replace_last, remove_last

This commit is contained in:
Jun Yang
2022-12-02 23:54:58 +08:00
parent f47d91a9a6
commit 46ffe036a8
5 changed files with 38 additions and 2 deletions
+2
View File
@@ -54,8 +54,10 @@ filters:
raw: raw.html
remove: remove.html
remove_first: remove_first.html
remove_last: remove_last.html
replace: replace.html
replace_first: replace_first.html
replace_last: replace_last.html
reverse: reverse.html
round: round.html
rstrip: rstrip.html
+1 -1
View File
@@ -10,7 +10,7 @@ There's 40+ filters supported by LiquidJS. These filters can be categorized into
Categories | Filters
--- | ---
Math | plus, minus, modulo, times, floor, ceil, round, divided_by, abs, at_least, at_most
String | append, prepend, capitalize, upcase, downcase, strip, lstrip, rstrip, strip_newlines, split, replace, replace_first, remove, remove_first, truncate, truncatewords
String | append, prepend, capitalize, upcase, downcase, strip, lstrip, rstrip, strip_newlines, split, replace, replace_first, replace_last,remove, remove_first, remove_last, truncate, truncatewords
HTML/URI | escape, escape_once, url_encode, url_decode, strip_html, newline_to_br
Array | slice, map, sort, sort_natural, uniq, where, first, last, join, reverse, concat, compact, size
Date | date
+1 -1
View File
@@ -10,7 +10,7 @@ LiquidJS 共支持 40+ 个过滤器,可以分为如下几类:
类别 | 过滤器
--- | ---
数学 | plus, minus, modulo, times, floor, ceil, round, divided_by, abs, at_least, at_most
字符串 | append, prepend, capitalize, upcase, downcase, strip, lstrip, rstrip, strip_newlines, split, replace, replace_first, remove, remove_first, truncate, truncatewords
字符串 | append, prepend, capitalize, upcase, downcase, strip, lstrip, rstrip, strip_newlines, split, replace, replace_first, replace_last, remove, remove_first, remove_last, truncate, truncatewords
HTML/URI | escape, escape_once, url_encode, url_decode, strip_html, newline_to_br
数组 | slice, map, sort, sort_natural, uniq, wheres, first, last, join, reverse, concat, compact, size
日期 | date
+17
View File
@@ -0,0 +1,17 @@
---
title: remove_last
---
{% since %}v10.2.0{% endsince %}
移除字符串中出现的最后一个指定子字符串。
输入
```liquid
{{ "I strained to see the train through the rain" | remove_last: "rain" }}
```
输出
```text
I strained to see the train through the
```
+17
View File
@@ -0,0 +1,17 @@
---
title: replace_last
---
{% since %}v10.2.0{% endsince %}
把字符串中出现的最后一个指定子字符串替换为另一个字符串。
输入
```liquid
{{ "Take my protein pills and put my helmet on" | replace_last: "my", "your" }}
```
输出
```text
Take my protein pills and put your helmet on
```