Creating a node template is not foreign to us; our process begins the same way we would create any Twig template. We begin by inspecting the markup of our page to identify which template is currently being used and the various file name suggestions available to us. Since our Post Listing block is referencing the listing view mode of our post content type, we can create a new Twig template called
Begin by grabbing a copy of the
node.html.twig template from
core/modules/node/templates and placing it into our
themes/octo/templates folder. We will then rename the file to
node--post--listing.html.twig so that we only affect the markup for this particular content types display. Next, we will ...