简体   繁体   中英

how do you add attributes to script tag in jade e.g. async defer

I needed to add async and defer attributes according to the docs for adding a google plus one button. How do I do this in jade?

<script src="https://apis.google.com/js/platform.js" async defer></script>

这对我有用:

script(async, defer, src='https://apis.google.com/js/platform.js')

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM