Pug mixins and lables

Pug mixins and lables
0

#1

I am new to Pug and mixins. This is the mixin I wrote; sorry if the indents are lost. Everything works except the label html generation.

mixin menuItem(prompt,fieldId,hint)
tr
td
label prompt
td
input(type=‘text’ id=fieldId name=fieldId placeholder=hint)

Here is my mixin call

+menuItem(‘Username’,‘email’,‘Email Address’)

The html generate “prompt” rather than “Username”. I am probably missing something basic. Any suggestions welcome.

Bill


#2

label= prompt fixes it