Technical Documentation Page - Build a Technical Documentation Page

Tell us what’s happening:

I have completed the challenge, I am not passing these two tests. I have tried everything please help me. -

  1. Each .nav-link should have text that corresponds to the header text of its related section (e.g. if you have a “Hello world” section/header, your #navbar should have a .nav-link which has the text “Hello world”)

  2. Your Technical Documentation project should use at least one media query.

Your code so far

<html lang="en">
  <head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>JavaScript Documentation</title>
    <link rel="stylesheet" href="style.css">
  </head>
  <body>
    <nav id="navbar">
      <header id="main-header">JS Documentation</header>
      <ul id="navbar-list">
        <li><a class="nav-link" href="#Intro">Intro</a></li>
        <li><a class="nav-link" href="#Prerequisites">Prerequisites</a></li>
        <li><a class="nav-link" href="#JavaScript_and_Java">JavaSript and Java</a></li>
        <li><a class="nav-link" href="#History">History</a></li>
        <li><a class="nav-link" href="#What_Next">What Next?</a></li>
        </ul>

      </nav>

      <main id="main-doc">

        <section class="main-section" id="Intro">
          <header>Intro</header>
          <p>JavaScript is a cross-platform, object-oriented scripting language. It is a small and lightweight language. Inside a host environment (for example, a web browser), JavaScript can be connected to the objects of its environment to provide programmatic control over them</p>

        <ul>
          <li>Client-side JavaScript extends the core language by supplying objects to control a browser and its Document Object Model (DOM).</li>
          <li>Server-side JavaScript extends the core language by supplying objects relevant to running JavaScript on a server.</li>
        

        </ul>

        <p>For Example:

        <code>var myVar = 69; <br>console.log myVar(); </code>

        </section>

        <section class="main-section" id="Prerequisites">
          <header>Prerequisites</header>
          <p>This guide assumes you have the following basic background:</p>
            <ul>
                <li>A general understanding of the Internet and the World Wide Web (WWW)</li>
                <li>Good working knowledge of HyperText Markup Language (HTML).</li>
                <li>Some programming experience. If you are new to programming, try one of the tutorials linked on the main page about JavaScript.</li>
            </ul>
        </section>

        <section class="main-section" id="JavaScript_and_Java">
          <header>JavaScript and Java</header>
        
        <p>JavaScript and Java are similar in some ways but fundamentally different in some others. The JavaScript language resembles Java but does not have Java's static typing and strong type checking. JavaScript follows most Java expression syntax, naming conventions and basic control-flow constructs which was the reason why it was renamed from LiveScript to JavaScript.
            <br><br></p>
            <p>
            In contrast to Java's compile-time system of classes built by declarations, JavaScript supports a runtime system based on a small number of data types representing numeric, Boolean, and string values. JavaScript has a prototype-based object model instead of the more common class-based object model. The prototype-based model provides dynamic inheritance; that is, what is inherited can vary for individual objects. JavaScript also supports functions without any special declarative requirements. Functions can be properties of objects, executing as loosely typed methods.
            <br><br></p>
            <p>JavaScript is a very free-form language compared to Java. You do not have to declare all variables, classes, and methods. You do not have to be concerned with whether methods are public, private, or protected, and you do not have to implement interfaces. Variables, parameters, and function return types are not explicitly typed.</p>
            <br>
            <p>JavaScript example: <br></p>
            <code>function greetMe(yourName) { 
                alert("Hello " + yourName); 
            }<br>
                greetMe("World");</code>
                <p>Java example <br></p>
            <code>public class HelloWorld {
                public static void main(String[] args) {
                    System.out.println("Hello, World!");
                }
            }
            </code>
        </section>
        <section class="main-section" id="History">
          <header>History</header>
          <p>JavaScript is a high-level, versatile, and widely-used programming language primarily used for creating interactive and dynamic content on the web. It was originally developed by Netscape, Inc. and first released in 1995.</p>
            <ul>
                
                <li>JavaScript was created by Brendan Eich while working at Netscape Communications Corporation. It was initially called "Mocha" and was later renamed to "LiveScript."</li>
                <p>For Example:</p>
                <code>log 'Hello, World!'
                </code>
                <li>The language was submitted to ECMA International for standardization. ECMAScript, the standard upon which JavaScript is based, was first published in 1997 as ECMA-262.</li>
                <p>For Example:</p>
                <code>add = (a, b) -> a + b
                    log add(3, 5)
                    
                </code>
                <li>JavaScript has continued to evolve, with regular updates to the ECMAScript standard (ES2016, ES2017, ES2018, etc.). Each new version brings enhancements, features, and improvements to the language, making it more powerful and developer-friendly.</li>
            </ul>
        </section>

        <section class="main-section" id="What_Next">
          <header>What Next</header>

          <p style="font-weight: bold;">Nothing. Go Take a bong, grab a drink or i dont know.<br>Go Out Nerd and Do something with your life.</p>  
        <p>Thank You So Much. Hope You have a great day.</p>
        </section>

      </main>
	
  </body>
</html>
/* css reset */
* {
  margin: 0;
}

body {
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  line-height: 1.5;
  background-color: #f1f1f1;
}

#main-header {
  position: fixed;
  top: 0;
  left: 0;
  height: 100%;
  min-width: 280px;
  max-width: 300px;
}

#navbar {
  height: 100%;
  border-right: solid 2.5px #333;
}

#navbar>h1 {
  font-size: 1.6rem;
  text-align: center;
  padding: 1rem 0;
}

#navbar ul {
  padding: 0;
  overflow-y: auto;
  overflow-x: hidden;
  height: 90%;
  list-style: none;
}

#navbar ul li {
  border: solid 1.3px #333;
}

#main-header #navbar ul li a {
  display: block;
  text-align: left;
  padding: .8rem 1rem .8rem 2rem;
  cursor: pointer;
  color: #222;
  text-decoration: none;
}


/* main section */
#main-doc {
  position: absolute;
  margin-left: 320px;
  padding: 2rem 1rem;
}

#main-doc .main-section header {
  font-size: 2rem;
  padding: 1rem 0;
}

#main-doc .main-section .main-article {
  padding-left: 1.5rem;
  margin-bottom: .5rem;
  color: #222;
}

#main-doc .main-section .main-article p {
  margin-bottom: 1rem;
}

#main-doc .main-section .main-article ul {
  margin: 1.3rem 0 0 1.2rem;
}

#main-doc .main-section .main-article ul li {
  margin-bottom: 1rem;
}

#main-doc .main-section .main-article code {
  display: block;
  padding: 1.5rem;
  text-align: left;
  background-color: #ddd;
  border-radius: 7px;
  margin-bottom: 1rem;
}

#main-doc .main-section:last-child .main-article ul {
  margin: .5rem 0 1.5rem 3rem;
  padding: 0;
}

#creator {
  text-align: left;
  padding: 2rem 0 0;
}

/* mobile-devices */
@media (max-width: 600px) {
  #main-header {
    position: absolute;
    top: 0;
    width: 100%;
    margin: 0;
    max-width: 95%;
    max-height: 400px;
  }

  #navbar {
    width: 100%;
    margin: 0;
  }

  #main-doc {
    position: relative;
    margin-left: 0px;
    padding: 2rem 1rem;
    margin-top: 410px;
  }

}

Your browser information:

User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/117.0.0.0 Safari/537.36 Edg/117.0.2045.41

Challenge: Technical Documentation Page - Build a Technical Documentation Page

Link to the challenge:

double check each of your link href’s. they need to be exactly the same except for using Underscores in place of spaces. That means punctuation, uppercase, numbers. Look at your media query again. there is definitely something missing. Check your punctuation and brackets. I get tripped up with this sometimes as well.

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.