Getting Started

Doc could use improvement:

Useful:

PugHtml - Pug and HTML online converter in realtime

Basics

form(@submit.prevent="onSubmit")
	input(
		required
		value="foo"
		name=foobar
	)

each i in [1,2,3000]
	p i
	| Just free text

Comments

https://pugjs.org/language/comments.html

// html comment
//- pug comment
//-
	Block comment
	very block comment

Interpolation

p(class=value)

input(value=`This is not ${"documented"}`)
- var title = "On Dogs: Man's Best Friend";
- var author = "enlore";
- var theGreat = "<span>escape!</span>";

h1= title
p Written with love by #{author}
p This will be safe: #{theGreat}

Loops (Iteration)

each val in [0,3,1000]
	p val