Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

JavaScript Express Basics (2015) Using Templates with Express Scaffolding Your Project’s Templates

Anthony Scott
PLUS
Anthony Scott
Courses Plus Student 9,001 Points

indents causing issues

I am having a hard time with indents in this lesson I keep getting this error:

Error: /Users/antkn33/express-basics/src/templates/index.jade:3
    1| 
    2| extends ./layout.jade             
  > 3|              header
    4|                  .header-content
    5|                      .header-content-inner
    6|                          h1 Fitness meets data science.

unexpected token "indent"

here is my index.jade

extends ./layout.jade             
                header
                    .header-content
                        .header-content-inner
                            h1 Fitness meets data science.
                            |                 
                            hr
                            |                 
                            p
                                | FitLog allows you to easily log and track workouts.  Analyze your results and progress. Push yourself to be the best you can be, while you maximize your recovery.
                            |                 
                            a.btn.btn-primary.btn-xl.page-scroll(href='#about') Sign up now!
                |     
                section#about.bg-primary
                    .container
                        .row
                            .col-lg-8.col-lg-offset-2.text-center
                                h2.section-heading Unleash the competitor.
                                |                     
                                hr.light
                                |                     
                                p.text-faded
                                    | Labore XOXO kogi, laborum tousled assumenda sriracha before they sold out. Labore mlkshk Helvetica Marfa health goth Austin magna sunt, yr aesthetic artisan heirloom chillwave commodo lo-fi.
                                |                     
                                a.btn.btn-default.btn-xl(href='#') Get Started!
                |     
                section#services
                    .container
                        .row
                            .col-lg-12.text-center
                                h2.section-heading Powerful tech, at your finger tips.
                                |                     
                                hr.primary
                    |         
                    .container
                        .row
                            .col-lg-3.col-md-6.text-center
                                .service-box
                                    i.fa.fa-4x.fa-diamond.wow.bounceIn.text-primary
                                    |                         
                                    h3 Easy Logging
                                    |                         
                                    p.text-muted Easily input your workout data, straight from your mobile device.
                            |                 
                            .col-lg-3.col-md-6.text-center
                                .service-box
                                    i.fa.fa-4x.fa-paper-plane.wow.bounceIn.text-primary(data-wow-delay='.1s')
                                    |                         
                                    h3 Predictive Analytics
                                    |                         
                                    p.text-muted Custom analytics, just for you.  Analyze past results, predict future performance.
                            |                 
                            .col-lg-3.col-md-6.text-center
                                .service-box
                                    i.fa.fa-4x.fa-newspaper-o.wow.bounceIn.text-primary(data-wow-delay='.2s')
                                    |                         
                                    h3 Access Anywhere
                                    |                         
                                    p.text-muted Your next workout is waiting.  Set goals, and access metrics right from the gym.
                            |                 
                            .col-lg-3.col-md-6.text-center
                                .service-box
                                    i.fa.fa-4x.fa-heart.wow.bounceIn.text-primary(data-wow-delay='.3s')
                                    |                         
                                    h3 Safe and Secure
                                    |                         
                                    p.text-muted We protect your data with the utmost integrity.  Your privacy is our priority.
                |     
                aside.bg-dark
                    .container.text-center
                        .call-to-action
                            h2 Meet athletes like you!
                            |                 
                            a.btn.btn-default.btn-xl.wow.tada(href='#') Start your free trial!
                | 
                section#portfolio.no-padding
                    .container-fluid
                        .row.no-gutter
                            .col-lg-4.col-sm-6
                                a.portfolio-box(href='#')
                                    img.img-responsive(src='/static/img/portfolio/1.jpg', alt='')
                                    |                         
                                    .portfolio-box-caption
                                        .portfolio-box-caption-content
                                            .project-category.text-faded
                                                | Endurance Athlete
                                            |                                 
                                            .project-name
                                                | Marge Simpson
                            |                 
                            .col-lg-4.col-sm-6
                                a.portfolio-box(href='#')
                                    img.img-responsive(src='/static/img/portfolio/2.jpg', alt='')
                                    |                         
                                    .portfolio-box-caption
                                        .portfolio-box-caption-content
                                            .project-category.text-faded
                                                | Weight Lifter
                                            |                                 
                                            .project-name
                                                | Jack Johnson
                            |                 
                            .col-lg-4.col-sm-6
                                a.portfolio-box(href='#')
                                    img.img-responsive(src='/static/img/portfolio/3.jpg', alt='')
                                    |                         
                                    .portfolio-box-caption
                                        .portfolio-box-caption-content
                                            .project-category.text-faded
                                                | Endurance Athlete
                                            |                                 
                                            .project-name
                                                | Reda Niman
                            |                 
                            .col-lg-4.col-sm-6
                                a.portfolio-box(href='#')
                                    img.img-responsive(src='/static/img/portfolio/4.jpg', alt='')
                                    |                         
                                    .portfolio-box-caption
                                        .portfolio-box-caption-content
                                            .project-category.text-faded
                                                | CrossFitter
                                            |                                 
                                            .project-name
                                                | Magnus Jorgenson
                            |                 
                            .col-lg-4.col-sm-6
                                a.portfolio-box(href='#')
                                    img.img-responsive(src='/static/img/portfolio/5.jpg', alt='')
                                    |                         
                                    .portfolio-box-caption
                                        .portfolio-box-caption-content
                                            .project-category.text-faded
                                                | Weight Lifter
                                            |                                 
                                            .project-name
                                                | Liz Vasques
                            |                 
                            .col-lg-4.col-sm-6
                                a.portfolio-box(href='#')
                                    img.img-responsive(src='/static/img/portfolio/6.jpg', alt='')
                                    |                         
                                    .portfolio-box-caption
                                        .portfolio-box-caption-content
                                            .project-category.text-faded
                                                | CrossFitter
                                            |                                 
                                            .project-name
                                                | Fit Fittington
                |         
                section#contact
                    .container
                        .row
                            .col-lg-8.col-lg-offset-2.text-center
                                h2.section-heading Who we are
                                |                     
                                hr.primary
                                |                     
                                p
                                    | At Treehouse, we love to show you how realistic projects are built.  There's a lot going on here, but you'll be ready to roll after this course.
                            |                 
                            .col-lg-4.col-lg-offset-2.text-center
                                i.fa.fa-phone.fa-3x.wow.bounceIn
                                |                     
                                p 800-4Fit-Log
                            |                 
                            .col-lg-4.text-center
                                i.fa.fa-envelope-o.fa-3x.wow.bounceIn(data-wow-delay='.1s')
                                |                     
                                p
                                    a(href='mailto:huston@teamtreehouse.com') Email your teacher!
Anthony Scott
Anthony Scott
Courses Plus Student 9,001 Points

I tried having no indent before the header and I get no error, however I also get no body content, just the nav bar.

4 Answers

Andres Ramirez
Andres Ramirez
18,094 Points

I am having the same issue, but adding the "block content" line does not solve the issue. Still not showing any content below the nav menu.

Anthony Scott
PLUS
Anthony Scott
Courses Plus Student 9,001 Points

I finally just went through the file and moved every line all the way to left. Then I tabbed out each line to its proper place and it worked after that.

Andres Ramirez
Andres Ramirez
18,094 Points

I just moved to the next video and downloaded the files again, that worked! I tried everything with indentation for no success... Time to move on!! Thanks :)