【发布时间】:2018-09-13 09:01:18
【问题描述】:
我同时使用 Google AMP (moustache.js) 和 Laravel Blade。 According to Laravel,我所要做的就是在括号前添加@。
我可以做到的:
<!-- Grid-->
<amp-list width="auto"
height="100"
layout="fixed-height"
src="/api/activity/all"
[src]="acts.data"
class="m1"
items="data">
<template type="amp-mustache">
<amp-img width="108" height="70" src="@{{cover}}"></amp-img>
</template>
</amp-list>
但是,在内联样式中添加 AMP 列表呈现的值不起作用。
<div style="background-image:@{{cover}}; width: 100%; height: 400px; "></div>
顺便说一句...现在可以在 AMP 中进行内联样式设置。
【问题讨论】:
标签: php laravel laravel-blade amp-html