【问题标题】:How to use AngularJS custom elements with jade?如何将 AngularJS 自定义元素与玉一起使用?
【发布时间】:2015-07-31 09:07:58
【问题描述】:

我遇到了一个问题,我不能告诉jade 渲染我的angularjs 来源(指令)的自定义元素,我想知道是否有任何方法可以转义标签,所以至少它们可能会按原样渲染寻找翡翠预处理器,或者是一种告诉翡翠以某种方式呈现我的自定义元素的方法。

当前代码如下:

html
  head
    link(href='/main.css', rel='stylesheet')
    script(src='/lib.js')
    script(src='/main.js')
    title!= "Neuron@l"
    meta(charset="utf-8")
    link(rel="icon",href="/images/neuronal.png")
  body(ng-app="app",ng-view)
    "<top:bar></top:bar>"
    "<left:bar></left:bar>"

【问题讨论】:

    标签: angularjs node.js pug


    【解决方案1】:

    如果是top:barleft:bar 的问题,这里是解决方案:

    html
      head
        link(href='/main.css', rel='stylesheet')
        script(src='/lib.js')
        script(src='/main.js')
        title!= "Neuron@l"
        meta(charset="utf-8")
        link(rel="icon",href="/images/neuronal.png")
      body(ng-app="app",ng-view)
        top:bar
        left:bar
    

    【讨论】:

    • 哦,是的,解决了你是对的,我尝试过类似的方法,但错误出现在其他地方,有角度删除了标记,谢谢。至少这现在会在其他人的结果中弹出。
    猜你喜欢
    • 1970-01-01
    • 2019-09-22
    • 2012-09-27
    • 2017-08-21
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2017-11-09
    • 2021-05-25
    相关资源
    最近更新 更多