Pen Settings

HTML

CSS

CSS Base

Vendor Prefixing

Add External Stylesheets/Pens

Any URLs 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 its URL and the proper URL extension.

+ add another resource

JavaScript

Babel includes JSX processing.

Add External Scripts/Pens

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.

+ add another resource

Packages

Add Packages

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.

Behavior

Auto Save

If active, Pens will autosave every 30 seconds after being saved once.

Auto-Updating Preview

If enabled, the preview panel updates automatically as you code. If disabled, use the "Run" button to update.

Format on Save

If enabled, your code will be formatted when you actively save your Pen. Note: your code becomes un-folded during formatting.

Editor Settings

Code Indentation

Want to change your Syntax Highlighting theme, Fonts and more?

Visit your global Editor Settings.

HTML

              
                <article>
    <aside>
        <svg onclick="render_error.reset().play();" id="render_error" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 809 375">
            <path d="M218 49H82l-14 92a192 192 0 0 1 29-2c27 0 55 6 77 19 28 16 51 47 51 92 0 70-55 122-133 122-39 0-72-11-89-22l12-37c15 9 44 20 77 20 45 0 84-30 84-78 0-46-31-79-103-79-20 0-36 2-49 4L47 9h171zM524 183c0 122-45 189-124 189-70 0-117-65-118-184C282 68 333 3 406 3c75 0 118 67 118 180zm-194 6c0 93 29 146 73 146 49 0 73-58 73-149 0-88-23-146-73-146-42 0-73 51-73 149zM806 183c0 122-45 189-124 189-70 0-117-65-118-184C564 68 615 3 688 3c75 0 118 67 118 180zm-194 6c0 93 29 146 73 146 49 0 73-58 73-149 0-88-23-146-73-146-42 0-73 51-73 149z"/>
        </svg>
        <h1>Ooops - Error 500</h1>
        <p>Please contact your administrator
    </aside>
</article>
              
            
!

CSS

              
                @import url("https://fonts.googleapis.com/css?family=Montserrat:400,400i,700");
body {
    background-color: #330000;
    font-family: "Montserrat", sans-serif;
}
article {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100vh;
    box-sizing: border-box;
}
aside {
    flex: 0 0 75vw;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 2em;
    box-sizing: border-box;
}
h1,
p {
    color: #fff;
    font-size: 3em;
    padding: 0;
    margin: 0;
}
p {
    font-size: 1em;
}
#render_error {
    fill: none;
    stroke: #f00;
    stroke-width: 3;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-miterlimit: 10;
}

              
            
!

JS

              
                render_error = new Vivus('render_error', {type: 'oneByOne', duration: 500});

/*

The following URLs and/or libraries were used to help in making this pen:

* Vivus.js (https://maxwellito.github.io/vivus/)
* SVGOMG (https://jakearchibald.github.io/svgomg/)
* Flexbox StackOverflow question concerning centered Flexbox (because I still forget!) (https://stackoverflow.com/questions/25832340/css-flexbox-vertically-horizontally-center-image-without-explicitely-defining-pa)

*/
              
            
!
999px

Console