-
-
Notifications
You must be signed in to change notification settings - Fork 125
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* chore: Добавлена рекомендация компонента для линтинга md файлов * style: Исправлены ошибки форматирования
- Loading branch information
1 parent
bc54f11
commit 35aad90
Showing
16 changed files
with
1,336 additions
and
1,056 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
{ | ||
"recommendations": ["DavidAnson.vscode-markdownlint"] | ||
} |
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,40 +1,45 @@ | ||
# Сниппеты | ||
|
||
## getCarts | ||
## getCarts | ||
|
||
Сниппет предназначен для вывода корзин на странице. Имеет только один параметр **tpls**, который принимает в качестве значения строку в формате JSON. | ||
|
||
### Fenom | ||
|
||
```fenom:line-numbers | ||
{'!getCarts' | snippet: [ | ||
'tpls' => '{ | ||
"maincart": | ||
{ | ||
"wrapper":"@FILE msac/cart.tpl","row":"@FILE msac/cartrow.tpl" | ||
} | ||
}' | ||
'tpls' => '{ | ||
"maincart": { | ||
"wrapper": "@FILE msac/cart.tpl","row":"@FILE msac/cartrow.tpl" | ||
} | ||
}' | ||
]} | ||
{'maincart' | placeholder} | ||
``` | ||
|
||
### Стандартный синтаксис | ||
|
||
```modx:line-numbers | ||
[[!getCarts? | ||
&tpls=`{ | ||
"maincart": { | ||
"wrapper":"@FILE msac/cart.tpl","row":"@FILE msac/cartrow.tpl" | ||
} | ||
}` | ||
&tpls=`{ | ||
"maincart": { | ||
"wrapper":"@FILE msac/cart.tpl","row":"@FILE msac/cartrow.tpl" | ||
} | ||
}` | ||
]] | ||
[[+maincart]] | ||
``` | ||
|
||
:::danger | ||
Не смешивайте синтаксис: если сниппет вызван на страндартном синтаксисе, то плейсхолдеры вставляйте на стандартном. И не используйте в именах плейсхолдеров ничего кроме цифр и латиницы. | ||
Не смешивайте синтаксис: если сниппет вызван на страндартном синтаксисе, то плейсхолдеры вставляйте на стандартном. И не используйте в именах плейсхолдеров ничего кроме цифр и латиницы. | ||
::: | ||
|
||
:::danger | ||
Ключ объекта в параметре tpls и есть имя плейсхолдера для вставки в шаблоне. | ||
::: | ||
|
||
## msacConnector | ||
|
||
Сниппет предназначен для обработки запросов с фронта. Его никогда и нигде не нужно вызывать. |
Oops, something went wrong.