2

为什么这不起作用?

extends layout

mixin WhyNotDefined(text)
  p #{text}

append content
  mixin WhyNotDefined('Hi')

我不断收到错误:WhyNotDefined_mixin is not defined

玉@0.20.3; 节点 v0.6.14

更新。

愚蠢的我,应该在块中定义mixin。这有效:

extends layout

append content
  mixin WhyNotDefined(text)
    p #{text}

  mixin WhyNotDefined('Hi')
4

1 回答 1

2

愚蠢的我,应该在块中定义mixin。这有效:

extends layout

append content
  mixin WhyNotDefined(text)
    p #{text}

  mixin WhyNotDefined('Hi')
于 2012-06-07T10:12:25.367 回答