Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Block content not render #3432

Open
EmmanuelLefevre opened this issue Apr 11, 2024 · 2 comments
Open

Block content not render #3432

EmmanuelLefevre opened this issue Apr 11, 2024 · 2 comments

Comments

@EmmanuelLefevre
Copy link

EmmanuelLefevre commented Apr 11, 2024

Hello, i try to use Pug, it seems there is a problem with the block content rendering. Even if i put the home.pug file in the same directory as my layout.pug, nothing is render!!! Includes works though..
I've also try relative or absolute path on extends, downgrade my node version to v16 but nothing works.

layout.pug =>

doctype html
html(lang="fr")
  head
    meta(charset="UTF-8")
    meta(name="viewport", content="width=device-width, initial-scale=1.0")
    link(rel="stylesheet", href="assets/css/main.css")
    script(src="https://unpkg.com/[email protected]")
    title Artiwave

  body

    block header
      include ../includes/header

    block appContent

    block footer
      include ../includes/footer

home.pug =>

extends ./layout

block appContent
  main
    p Hello Artiwave

NodeJS v20.10.0
Express 4.18.12
Pug 3.0.2

@jeromew
Copy link
Contributor

jeromew commented Apr 11, 2024

https://pugjs.org/language/inheritance.html
have you tried extends layout.pug

other than that, stackoverflow is your best bet I think

@EmmanuelLefevre
Copy link
Author

Yes i've already try to put extension name after the file..

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants