November 2018
Beginner
132 pages
2h 57m
English
To keep our template code reusable, we can introduce partials. We will essentially create two partials given here:
Both partials will be placed in a partials folder within the views folder. We can create both files and place the required contents in them. For the header file, use the code given:
<!-- ./views/partials/header.ejs --><!DOCTYPE html><html><head> <meta charset="utf-8"> <meta name="viewport" content="width=device-width, initial-scale=1"> <title>Welcome - KoaBlog</title> <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/bulma/0.7.2/css/bulma.min.css"></head> ...
Read now
Unlock full access