4.6.201910301108 • Published 5 years ago
@dfeidao/fd-aw000023 v4.6.201910301108
html渲染
Params
Name | Type | describe |
---|---|---|
fd | 固定参数 | |
data | unknown | 要渲染的数据 |
tpl | string | 渲染片段tpl |
panme | string | p块的名称 |
position | “after” | “before” | “firstin” | “lastin” | “replace” | “inner” | 渲染位置 |
Example
tpl.tpl
<div>
<div data-feidao-presentation='p01'></div>
</div>
p01.tpl
{{~it:v:i}}
<span>{{=v.staff_no}}!</span>
{{~}}
import aw23 from '@dfeidao/fd-aw000023';
import p01 from './p01';
const data = [{ staff_no: '1' }, { staff_no: '2' }];
aw23(fd, data, p01, 'p01', 'inner');