From 94ac98d5366b2293977b7451d9eb4f483ad11cb3 Mon Sep 17 00:00:00 2001 From: Jet Hughes Date: Wed, 21 Sep 2022 13:09:30 +1200 Subject: [PATCH] vault backup: 2022-09-21 13:09:30 --- content/notes/11-mvc-model.md | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) create mode 100644 content/notes/11-mvc-model.md diff --git a/content/notes/11-mvc-model.md b/content/notes/11-mvc-model.md new file mode 100644 index 000000000..4356c683a --- /dev/null +++ b/content/notes/11-mvc-model.md @@ -0,0 +1,28 @@ +--- +title: "11-mvc-model" +aliases: +tags: +- cosc203 +- lecture +--- + +![mvc model diagram|400](https://i.imgur.com/Ini1bwk.png) + +# view templates +## pug +pug is a view engine. +``` js +app.set('views', path.join(__dirname, 'views')) +app.set('view engine', 'pug') +``` + +a pug file +- defines an html template + +e.g., +``` pug +doctype html +head + title mytitle + script(type="text/javascript") +``` \ No newline at end of file