I have set up a modular page in my custom grav theme. But the modules / sections in that modular page render out of the container in base twig template

I have used container class of tailwind to the main container which holds the content within it but it is holding only the first two modules. I have checked all the necessary files and grav admin but everything seems to be correct

Check the theme templates

above are my base twig template. everything is correct but didn’t get where is the issue


This is the modular twig template

  1. Please paste actual code in the future and not images
  2. These two images don’t show anything useful
  3. Check your module templates
  4. Don’t use element inspector - open page source
    Either some tags are not properly closed in the templates or you’re using some weird shortcodes without closing them. I think it’s the latter, but you’re not providing relevant info.

Please read the sticky topic about asking good questions

Hey i checked the source code and the modules are rendering inside the main container that is in the base template but the issue is that from the 3rd module it renders outside the main container resulting in no margin to it as i have given a margin to the main container

So did you check your markdown in the second and third modules as I suggested?

@_shreyas04, Any progress you would like to share?

Some questions:

  • What’s your level of expertise in Tailwind and CSS?
  • Do you know how to use the devtools of the browser?
  • Do you have a website we can inspect?