HTML preprocessors can make writing HTML more powerful or convenient. For instance, Markdown is designed to be easier to write and read for text documents and you could write a loop in Pug.
In CodePen, whatever you write in the HTML editor is what goes within the <body>
tags in a basic HTML5 template. So you don't have access to higher-up elements like the <html>
tag. If you want to add classes there that can affect the whole document, this is the place to do it.
In CodePen, whatever you write in the HTML editor is what goes within the <body>
tags in a basic HTML5 template. If you need things in the <head>
of the document, put that code here.
The resource you are linking to is using the 'http' protocol, which may not work when the browser is using https.
CSS preprocessors help make authoring CSS easier. All of them offer things like variables and mixins to provide convenient abstractions.
It's a common practice to apply CSS to a page that styles elements such that they are consistent across all browsers. We offer two of the most popular choices: normalize.css and a reset. Or, choose Neither and nothing will be applied.
To get the best cross-browser support, it is a common practice to apply vendor prefixes to CSS properties and values that require them to work. For instance -webkit-
or -moz-
.
We offer two popular choices: Autoprefixer (which processes your CSS server-side) and -prefix-free (which applies prefixes via a script, client-side).
Any URL's added here will be added as <link>
s in order, and before the CSS in the editor. You can use the CSS from another Pen by using it's URL and the proper URL extention.
You can apply CSS to your Pen from any stylesheet on the web. Just put a URL to it here and we'll apply it, in the order you have them, before the CSS in the Pen itself.
You can also link to another Pen here (use the .css
URL Extension) and we'll pull the CSS from that Pen and include it. If it's using a matching preprocessor, use the appropriate URL Extension and we'll combine the code before preprocessing, so you can use the linked Pen as a true dependency.
JavaScript preprocessors can help make authoring JavaScript easier and more convenient.
Babel includes JSX processing.
Any URL's added here will be added as <script>
s in order, and run before the JavaScript in the editor. You can use the URL of any other Pen and it will include the JavaScript from that Pen.
You can apply a script from anywhere on the web to your Pen. Just put a URL to it here and we'll add it, in the order you have them, before the JavaScript in the Pen itself.
If the script you link to has the file extension of a preprocessor, we'll attempt to process it before applying.
You can also link to another Pen here, and we'll pull the JavaScript from that Pen and include it. If it's using a matching preprocessor, we'll combine the code before preprocessing, so you can use the linked Pen as a true dependency.
Search for and use JavaScript packages from npm here. By selecting a package, an import
statement will be added to the top of the JavaScript editor for this package.
Using packages here is powered by Skypack, which makes packages from npm not only available on a CDN, but prepares them for native JavaScript ES6 import
usage.
All packages are different, so refer to their docs for how they work.
If you're using React / ReactDOM, make sure to turn on Babel for the JSX processing.
If active, Pens will autosave every 30 seconds after being saved once.
If enabled, the preview panel updates automatically as you code. If disabled, use the "Run" button to update.
If enabled, your code will be formatted when you actively save your Pen. Note: your code becomes un-folded during formatting.
Visit your global Editor Settings.
<!DOCTYPE html>
<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">
<link rel="stylesheet" href="style.css">
<title>Technical Documentation Page</title>
</head>
<body>
<nav id="navbar">
<header><h1>Frontend Development Guide</h1></header>
<hr>
<ul>
<li><a class="nav-link" href="#INTRODUCTION">INTRODUCTION</a></li><hr>
<li><a class="nav-link" href="#RESPONSIVE_WEB_DESIGN">RESPONSIVE WEB DESIGN</a></li><hr>
<li><a class="nav-link" href="#THE_BASICS_(HTML_&_CSS)">THE BASICS (HTML & CSS)</a></li><hr>
<li><a class="nav-link" href="#CSS_FLEXBOX">CSS FLEXBOX</a></li><hr>
<li><a class="nav-link" href="#CSS_GRID">CSS GRID</a></li><hr>
<li><a class="nav-link" href="#JAVASCRIPT">JAVASCRIPT</a></li><hr>
<li><a class="nav-link" href="#FRONTEND_LIBRARIES">FRONTEND LIBRARIES</a></li><hr>
<li><a class="nav-link" href="#REFERENCE">REFERENCE</a></li>
</ul>
</nav>
<main id="main-doc">
<section class="main-section" id="INTRODUCTION">
<header><h2>INTRODUCTION</h2></header>
<p>
Before Starting
If you decided to study on your own, there is a lot of information on the Internet and it’s hard to wrap your head around everything. It’s important to have a structured plan and avoid wasting time by jumping from one resource to another.
Please note that these are just the first steps into the front-end universe. It will help you get started but it’s not intended to be a complete guide.
</p>
</section>
<section class="main-section" id="RESPONSIVE_WEB_DESIGN">
<header><h2>RESPONSIVE WEB DESIGN</h2></header>
<p>
Responsive Web Design entails you to make websites to fit on all kinds of screens both large and small ones, so you have to keep that in mind while learning front-end development.
</p>
</section>
<section class="main-section" id="THE_BASICS_(HTML_&_CSS)">
<header><h2>THE BASICS (HTML & CSS)</h2></header>
<p>
Basic HTML and HTML5 and Basic CSS sections are the fundamentals of the modern Internet. Applied Visual Design, Applied Accessibility, and Responsive Web Design Principles will teach you the basics of writing good websites. Don’t rush and step carefully, those are the main building blocks in your knowledge.
Next, you are going to learn powerful layout techniques like CSS Flexbox and CSS Grid. Before moving on, complete this short guide to get an overview of different layout techniques that people used before the Flexbox-Grid era. It’s unlikely that you will ever need to use them, but it’s always good to be aware and appreciate the technologies we have today.
<br><br>
A simple html syntax:<br>
<code>
 <h1>Hello World!</h1><br><br>
</code>
A simple css syntax:<br>
<code>
 li{text-decoration: none;<br>
   color: black;} <br>
</code>
</p>
</section>
<section class="main-section" id="CSS_FLEXBOX">
<header><h2>CSS FLEXBOX</h2></header>
<p>
The Flexible Box Module, usually referred to as flexbox, was designed as a one-dimensional layout model, and as a method that could offer space distribution between items in an interface and powerful alignment capabilities.
<br><br>
When we describe flexbox as being one dimensional we are describing the fact that flexbox deals with layout in one dimension at a time — either as a row or as a column. This can be contrasted with the two-dimensional model of CSS Grid Layout, which controls columns and rows together.
<br><br>
Tip: Try practicing css flexbox <a href="https://flexboxfroggy.com/">@Flexboxfroggy</a>
<br>
  Read more on css flexbox <a href="https://developer.mozilla.org/en-US/docs/Web/CSS/CSS_Flexible_Box_Layout/Basic_Concepts_of_Flexbox">@MDN web docs</a>
</p>
</section>
<section class="main-section" id="CSS_GRID">
<header><h2>CSS GRID</h2></header>
<p>
CSS Grid Layout excels at dividing a page into major regions or defining the relationship in terms of size, position, and layer, between parts of a control built from HTML primitives.
<br><br>
Like tables, grid layout enables an author to align elements into columns and rows. However, many more layouts are either possible or easier with CSS grid than they were with tables. For example, a grid container's child elements could position themselves so they actually overlap and layer, similar to CSS positioned elements.
<br><br>
Tip: Try practicing css grid <a href="https://cssgridgarden.com/">@Gridgarden</a>
<br>
  Read more on css grid <a href="https://developer.mozilla.org/en-US/docs/Web/CSS/CSS_Grid_Layout">@MDN web docs</a>
</p>
</section>
<section class="main-section" id="JAVASCRIPT">
<header><h2>JAVASCRIPT</h2></header>
<p>
Now you know how to build static websites and it’s time to learn JavaScript.
<br><br>
JavaScript® (often shortened to JS) is a lightweight, interpreted, object-oriented language with first-class functions, and is best known as the scripting language for Web pages, but it's used in many non-browser environments as well. It is a prototype-based, multi-paradigm scripting language that is dynamic, and supports object-oriented, imperative, and functional programming styles.
<br><br>
JavaScript runs on the client side of the web, which can be used to design / program how the web pages behave on the occurrence of an event. JavaScript is an easy to learn and also powerful scripting language, widely used for controlling web page behaviour.
<br><br>
A Simple JavaScript Syntax:<br>
<code>
var i = 'Hello World!'<br>
</code>
<code>
console.log(i);
</code>
<code>
Results:<br>
<code>
>Hello World!
</code>
</code>
</p>
</section>
<section class="main-section" id="FRONTEND_LIBRARIES">
<header><h2>FRONTEND LIBRARIES</h2></header>
<p>
From this point, you are becoming a real front end developer
<br>
<ul>
<li>
<h3>Bootstrap</h3>
<p>Bootstrap is an open source project created by Twitter. The goal is to make website responsive. Responsive meaning the layout of the website will change if the screen size changes. Bootstrap is a CSS alongside with JavaScript. Aka bootstrap.css and bootstrap.js.
</p>
</li>
<br>
<li>
<h3>jQuery</h3>
<p>
jQuery is a fast, small, and feature-rich JavaScript library. It makes things like HTML document traversal and manipulation, event handling, animation, and Ajax much simpler with an easy-to-use API that works across a multitude of browsers
</p>
</li>
<br>
<li>
<h3>Sass</h3>
<p>
Sass is a preprocessor scripting language that is interpreted or compiled into Cascading Style Sheets (CSS). SassScript is the scripting language itself. Sass consists of two syntaxes. The original syntax, called "the indented syntax," uses a syntax similar to Haml
</p>
</li>
<br>
<li>
<h3>React & Redux</h3>
<p>
Redux is a state management library, and is often used with React Native to simplify data flow within an app. ... Along the way, you'll learn about actions, reducers, selectors, and how to connect Redux to React Native components
</p>
</li>
</ul>
</p>
</section>
<section class="main-section" id="REFERENCE">
<header>
<h2>REFERENCE</h2>
</header>
<p>
<ul>
<li>freeCodeCamp News</li>
<br>
<li>MDN web docs</li>
</ul>
</p>
</section>
</main>
<script src="https://cdn.freecodecamp.org/testable-projects-fcc/v1/bundle.js"></script>
</body>
</html>
body{
background-color: aliceblue;
font-family: helvetica, Arial, sans-serif;
}
span{
font-weight: bold;
}
a:hover{
color: purple;
}
nav ul li{
list-style-type: none;
margin: 20px;
padding: 0px;
font-weight: 20PX;
}
nav{
top: 0px;
left: 0px;
border: 1px solid black;
position: fixed;
height: 100%;
overflow-y: auto;
overflow-x: hidden;
background-color: aliceblue;
margin: 0px;
padding: 0px;
}
li a{
text-decoration: none;
color: black;
}
h1{
text-align: center;
}
#main-doc{
margin-left: 354px;
}
code{
background-color: lightgray;
}
@media (max-width: 800px){
nav{
top: 0px;
border: 1px solid black;
position: relative;
height: 40%;
width: 100%;
overflow-y: auto;
overflow-x: hidden;
background-color: aliceblue;
margin: 0px;
padding: 0px;
}
#main-doc{
margin-left: 0px;
margin-top: 0px;
}
nav ul li{
list-style-type: none;
margin: 0px;
padding: 0px;
font-weight: 20PX;
}
}
Also see: Tab Triggers