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.
<main id="main">
<h1 id="title"><i>Tony Stark</i></h1>
<h3> Billionare, Genius, Playboy, Philanthropist </h3>
<figure id="img-div">
<img id="image" src="https://specials-images.forbesimg.com/imageserve/5d2392b234a5c400084abe23/960x0.jpg?fit=scale" alt="Tony Stark giving a thumbs-up to the crowd">
<figcaption id="img-caption">
Tony Stark giving a thumbs-up to the the crowd. Image courtesy of Forbes.
</figcaption>
</figure>
<section id="tribute-info">
<h2>The Life and Death of Anthony Edward Stark<br>A.K.A. Iron Man</br>
</h2>
<h4><u>Early Life</u></h4>
<p>Anthony Edward "Tony" Stark was born to Howard and Maria Stark on May 29, 1970. His childhood was characterized by a cold and affectionless relationship with his father, who was already famous as an inventor and businessman. He was also a child prodigy, graduating from MIT, summa cum laude, at age 17. On December 16, 1991, when Stark was 21, his parents were killed in a car accident (later revealed to be an assassination by a brainwashed Bucky Barnes aka the "Winter Soldier"). As a result, Stark inherited his father's company, becoming CEO of Stark Industries. Over the years, he became well known as a weapons designer and inventor, and lived a playboy lifestyle.
<br>In the late 2000s, Stark travels to war-torn Afghanistan with his friend and military liaison Lieutenant Colonel James Rhodes to demonstrate Stark's new "Jericho" missile. After the demonstration, the convoy is ambushed and Stark is critically wounded and imprisoned by a terrorist group, the Ten Rings. Fellow captive Yinsen, a doctor, implants an electromagnet into Stark's chest to keep shrapnel shards from reaching his heart and killing him. Ten Rings leader Raza offers Stark freedom in exchange for building a Jericho missile, but Tony and Yinsen agree Raza will not keep his word. Stark and Yinsen secretly build a small, powerful electric generator called an arc reactor to power Stark's electromagnet and a suit of powered armor. When the Ten Rings attack the workshop. Yinsen sacrifices himself to divert them while the suit is completed. The armored Stark battles his way out of the cave to find the dying Yinsen, then burns the Ten Rings' weapons in anger and flies away, crashing in the desert. Rescued by Rhodes, Stark returns home to announce that his company will no longer manufacture weapons. Obadiah Stane, his father's old partner and the company's manager, advises Stark that this may ruin Stark Industries and his father's legacy. With the aid of his computer J.A.R.V.I.S., Stark secretly builds a sleeker version of his improvised armor suit with a more powerful arc reactor.
<br>At a Stark Industries charity event, reporter Christine Everhart informs Stark that his company's weapons were being used by the Ten Rings to attack Yinsen's home village, Gulmira. Stark learns that Stane has been arms trafficking to criminals worldwide, and is staging a coup to replace him as Stark Industries' CEO. Stark, in his new armor, flies to Afghanistan and saves the villagers. Flying home, Stark is shot at by two F-22 Raptor fighter jets, forcing him to call Rhodes and reveal his secret identity. Stane acquires the wreckage of Stark's prototype from the Ten Rings, and has a massive new suit reverse engineered. Stane's scientists cannot duplicate Stark's miniaturized arc reactor, so Stane ambushes Stark at his home and takes the one from his chest, revealing that Stane was responsible for Stark's captivity. Stark manages to get to his original reactor to replace it, and defeats Stane. The next day, at a press conference, Stark defies suggestions from S.H.I.E.L.D. and publicly admits to being the superhero the press has dubbed "Iron Man".</p>
<h4><u>Notable Battles</u></h4>
<ul>
<li>The Battle of New York - Loki (with Thanos' army)</li>
<li>Stark Expo Attack - Ivan Vanko</li>
<li>The Battle of Sokovia - Ultron</li>
<li>The Infinity War - Thanos</li>
</ul>
<h4><u>Untimely Death</u></h4>
<p>In 2023, when Scott Lang seems to discover a way to travel through time, the Avengers approach Stark, who initially refuses, considering the idea dangerously hypothetical. Despite this he examines the matter privately, figures out how to do it successfully and agrees to help. Traveling through time, Stark fails to steal the Space Stone from an earlier version of himself following the Battle of New York, and instead goes further back to the 1970s to steal it from a S.H.I.E.L.D. facility, where he has a moving conversation with a younger version of his father, Howard Stark. The Avengers successfully obtain all of the Infinity Stones before returning to the present, which are incorporated into a gauntlet made by Stark which Banner then uses to resurrect those that were disintegrated by Thanos. However, they are followed by a 2014 version of Thanos and his forces, who are summoned to 2023 by Nebula, who had previously been captured by Thanos and also replaced by her 2014 self. Following a climactic battle, Thanos obtains Stark's gauntlet and the two of them wrestle for control of it. Thanos is able to fling Stark away before attempting another snap, but discovers that Stark has caused all of the Infinity Stones to move to Stark's own armor. Stark then uses them to disintegrate Thanos and all of his forces, saving the universe but fatally injuring himself in the process due to the gamma radiation caused by the stones. He dies peacefully, surrounded by Rhodes, Parker and Potts. The funeral was attended by many heroes was later held for him at his homestead. Months later, the world continues to mourn and idolize the deceased Stark with murals and graffiti being drawn to honor the fallen Avenger.</p>
<h3>Read the full story of Tony Stark
<a id="tribute-link" href="https://en.wikipedia.org/wiki/Tony_Stark_(Marvel_Cinematic_Universe)"
target="_blank">
here.</a>
</h3>
</section>
</main>
<footer>
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css">
<a href="https://www.linkedin.com/in/curtis-engler-018b52171/?originalSubdomain=ca" class="fa fa-linkedin" target="_blank"></a>
<a href="https://github.com/cl-engler" class="fa fa-github" target="blank">
</a>
</footer>
</main>
html {
font-size: 10px;
}
h1 {
font-family: Impact;
font-size: 70px;
}
main {
margin: 30px 8px;
padding: 15px;
border-radius: 5px;
background: #eee;
}
#image {
max-width: 960px;
display: block;
height: auto;
text-align: center;
margin: 0 auto;
}
body {
text-align: center;
font-size: 1.5rem;
}
#tribute-info {
max-width: 980px;
margin: auto;
}
h3 {
font-family: Courier, Monaco, monospace;
}
h2 {
font-size: 2.5rem;
font-family: Courier, Monaco, monospace;
background-color: rgba(45, 45, 45, 0.1);
}
p {
text-align: left;
font-size: 1.9rem;
line-height: 1.4;
}
li {
text-align: left;
font-size: 1.7rem;
}
h4 {
text-align: left;
font-size: 2.5rem;
}
footer .fa {
padding: 10px;
font-size: 20px;
width: 20px;
height: 20px;
line-height: 20px;
text-decoration: none;
}
.fa:hover {
opacity: 0.7;
}
.fa-linkedin {
background: #3B5998;
color: white;
border-radius: 50%;
}
.fa-github {
background: #333;
color: white;
border-radius: 50%;
}
// coded by @cl-engler
Also see: Tab Triggers