Pen Settings



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


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


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.


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.


                  <div class="tags">
    <span id="all"><button class="all">All</button></span>
  <span id="tags">
    <button class="archival">Archival</button>
    <button class="ai">AI</button>
    <button class="art">Art</button>
    <button class="education">Education</button>
    <button class="graphics">Graphics</button>
    <button class="html">HTML/CSS</button>
    <button class="layouts">Layouts</button>
    <button class="mental">Mental Health</button>
  <div id="posts">
    <div class="archival">
        <li><span><a href="" target="_blank">DownThemAll</a><br>
        Extension to allow you to download all of the images on a page</span></li>
        <li><span><a href="" target="_blank">TumblThree</a><br>
      Download entire archives of Tumblr blogs</span></li>
      <div class="ai">
          <li><span><a href="" target="_blank">AI Dungeon</a><br>
          An AI-generated interactive text adventure</span></li>
          <li><span><a href="" target="_blank">Inferkit</a><br>See how a modern neural network completes your text</span></li>
          <li><span><a href="" target="_blank">Bored Humans</a><br>A list of AI-generated tools.</span></li>
    <div class="art"><h3>Visual Art</h3>
        <li><span><a href="" target="_blank">AutoDraw</a><br>
        A drawing tool with the option to correct your shapes into clip-art</span></li>
        <li><span><a href="" target="_blank">Inspirograph</a><br>
        Create spirograph art in your browser</span></li>
        <li><span><a href="" target="_blank">JS Paint</a><br>
        Microsoft Paint in your browser - with Javascript</span></li>
        <li><span><a href="" target="_blank">NoPaint</a><br>
        If you like what you see, click on "Paint", or else click "No"</span></li>
        <li><span><a href="" target="_blank">Cheap Freedom</a><br>
          An online visual art museum open to anyone.</span></li>
   <div class="education">
     <li><span><a href="" target="_blank">Emotional Labor</a><br>
        A comprehensive archive of a Metafilter thread about emotional labor.</span></li>
      <li><span><a href="" target="_blank">Mental Models</a><br>
        A list of mental models for making intelligent decisions.</span></li>
      <li><span><a href="" target="_blank">Untools</a><br>
        Tools for decision making and problem solving.</span></li>
      <div class="graphics">
      <li><span><a href="" target="_blank">BoodleBox</a><br>
        Fake ads to use on your page</span></li>
      <li><span><a href="" target="_blank">The Corporation</a><br>
        More fake ads to use on your page</span></li>
      <li><span><a href="" target="_blank">EZ Gif</a><br>
        Create & edit gifs</span></li>
      <li><span><a href="" target="_blank">FlamingText</a><br>
        Generate word art</span></li>
      <li><span><a href="" target="_blank">Make Word Art</a><br>
        Generate Microsoft Office-esque word art</span></li>
      <li><span><a href="" target="_blank">GIFy Pet</a><br>
        Create a cute pet for your webpage</span></li>
      <li><span><a href="" target="_blank">PhotoMosh</a><br>
        Add glitchy and retro effects to photos and gifs</span></li>
      <li><span><a href="" target="_blank"></a><br>
        Upload an image and this tool will remove the background</span></li>
      <li><span><a href="" target="_blank">Repeater</a><br>
        Make your own tiled backgrounds</span></li>
      <li><span><a href="" target="_blank">SubtlePatterns</a><br>
        Free background patterns</span></li>
      <li><span><a href="" target="_blank">Web Badges World</a><br>
        A huge collection of web badges to display on your site</span></li>
      <li><span><a href="" target="_blank">Blinkie</a><br>
        Create your own blinkies</span></li>
    <div class="html"><h3>HTML/CSS</h3>
      <li><span><a href="" target="_blank">CSS Beautify</a><br>
        CSS formatter</span></li>
      <li><span><a href="" target="_blank">CodePen</a><br>
        A live editor that shows you HTML/CSS changes as you make them in real time</span></li>
      <li><span><a href="" target="_blank">Construct Your CSS</a><br>
        Visually create your layout and generate the code</span></li>
      <li><span><a href="" target="_blank">Lilac Lynx's Responsive Web Guide</a><br>
        Guide to make your site responsive</span></li>
      <li><span><a href="" target="_blank">HTML Cheatsheet</a><br>
        A handy reference sheet when using HTML</span></li>
      <li><span><a href="" target="_blank">HTML Generator</a><br>
        Generate the markup for lists, tables, links, images and more</span></li>
      <li><span><a href="" target="_blank">WebGuide</a><br>
        A good beginner's guide to HTML & CSS</span></li>
      <li><span><a href="" target="_blank">Word to HTML</a><br>
        Paste in formatted text and generate it into HTML</span></li>
    <div class="layouts"><h3>Layouts</h3>
           <li><span><a href="" target="_blank">LovelyD</a><br>
             Premade 00s anime layouts</span></li>
           <li><span><a href="" target="_blank">Celestial Star</a><br>
            More 00s premade anime layouts</span></li>
      <li><span><a href="" target="_blank">Templaterr</a><br>
        Premade layouts and useful site codes</span></li>
      <li><span><a href="" target="_blank">EggRamen</a><br>
        More free layouts</span></li>
      <li><span><a href="" target="_blank">TooPlate</a><br>
        Modern-looking premade layouts</span></li>
    <div class="mental">
      <h3>Mental Health</h3>
        <li><span><a href="" target="_blank">Emotional Codes</a><br>
          Tools for processing emotions</span></li>
        <li><span><a href="" target="_blank">Feelu Mood Wheel</a><br>
          An interactive mood wheel, to help identify how you're feeling</span></li>
        <li><span><a href="" target="_blank">Gentle Earth</a><br>
          Vent anonymously</span></li>
        <li><span><a href="" target="_blank">ASMRion</a><br>
          ASMR Generator with various sound effects</span></li>
        <li><span><a href="" target="_blank">A Soft Murmur</a><br>
          Ambient sounds to wash away distraction</span></li>
        <li><span><a href="" target="_blank">Purrli</a><br>
          Listen to HD cat purrs as background noise</span></li>
        <li><span><a href="" target="_blank">RainbowHunt</a><br>
          Listen to calming rain sounds with adjustable sliders</span></li>
        <li><span><a href="" target="_blank"></a><br>
          Tune into forests around the world (imagery and sound effects)</span></li>
        <li><span><a href="">Vibe Ocean</a><br>
          Ocean noise and ambient sounds generator</a><br>
    <li><span><a href="">myNoise</a><br>
          A comprehensive background noise generator</a><br>


                li {


// functionality:
// display a list of buttons which are tags at the top
// below the tags, display list of articles in div
// when a tag is clicked, hide the articles in the div and only display entry links which have a class that matches the tag

  const tags = document.querySelectorAll('#tags > button');
  const posts = document.querySelectorAll('#posts > div');
  const displayAll = document.getElementById('all');


displayAll.addEventListener('click', event => {
    for (let i = 0 ; i < posts.length; i++) {
      posts[i].style.display = "list-item";

for (let i = 0 ; i < tags.length; i++) {
  // when a tag button is clicked...
tags[i].addEventListener('click', event => {
  // identify which classes belong to button
  const buttonTag = tags[i].getAttribute('class');
  // loop through post tags
  for (let i = 0 ; i < posts.length; i++) {
    // get post tags
    const postTag = tags[i].getAttribute('class');
    // if the "all" button is clicked, display everything
    if (postTag === buttonTag) {
      // display posts
      posts[i].style.display = "block"
    // if the post tag does not match the button tag...
    else if (postTag != buttonTag) {
      // hide the other posts
      posts[i].style.display = "none"