Jade - Using Block inside script tag

会有一股神秘感。 提交于 2019-12-04 03:06:10
Arnaud Rinquin

Jade do not translate what's inside 'style' and 'script' code. Never.

What will work is based on an answer I gave to another question (using a style element but that's basically the same).

!!!
head
  title Hello jade
  | <script type='text/javascript'>
  | $(document).ready(function() {
      block js_doc_ready
  | });
  | </script>

This way : jade will include the HTML 'script' tags and $.ready lines but will also include your block.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!