dump filter: print the structure type and value of the variable

How to view the structure type of variables in Anqi CMS template?

dumpThe filter can print the structure, type, and value of a variable.

Usage method

dumpHow to use the filter:

{{ obj|dump }}

For example, to view the structure of bannerItem, you can write:

{{ item|dump }}
# 显示结果
&config.BannerItem{Logo:"http://127.0.0.1:8001/uploads/202309/14/eba5aa9dc4c45d18.webp", Id:1, Link:"", Alt:"Hello", Description:"", Type:"default"}