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

              
                <!DOCTYPE html>
<html>
   <head>
      <title>CSS is fun :)</title>
      
      <meta name="viewport" content="width=device-width, initial-scale=1.0">
   </head>
   <body>
     <div class = "one">
        <h1> This element used no-repeat value and background-position:left top</h1>
     </div>
     <div class = "two">
      <h1> This element used no-repeat value and background-position:left center</h1>
      </div>
      <div class = "three">
         <h1> This element used no-repeat value and background-position:left bottom</h1>
      </div>
      <div class = "four">
         <h1> This element used no-repeat value and background-position:center top</h1>
      </div>
      <div class = "five">
         <h1> This element used no-repeat value and background-position:center center </h1>
      </div>
      <div class = "six">
         <h1> This element used no-repeat value and background-position: center bottom;</h1>
      </div>
      <div class = "seven">
         <h1> This element used no-repeat value and background-position: right top;</h1>
      </div>
      <div class = "eight">
         <h1> This element used no-repeat value and background-position: right center;</h1>
      </div>
      <div class = "nine">
         <h1> This element used no-repeat value and background-position: right bottom;</h1>
      </div>
     
    
   </body>
</html>

              
            
!

CSS

              
                      *{
         margin:unset;
         box-sizing: border-box;
      }

      .one{
         width:21em;
         height:17em;
         border:medium solid lightseagreen;
         border-radius: 0.3em;

         background-image:url(https://enjoytutorials.com/hotlink-ok/photos/heart.jpg);
         background-repeat: no-repeat; 
         background-position: left top; /* default value */
      }
      .two{
         width:21em;
         height:17em;
         border:medium solid lightseagreen;
         border-radius: 0.3em;

         background-image:url(https://enjoytutorials.com/hotlink-ok/photos/heart.jpg);
         background-repeat: no-repeat;
         background-position: left center;
      }
      .three{
         width:21em;
         height:17em;
         border:medium solid lightseagreen;
         border-radius: 0.3em;

         background-image:url(https://enjoytutorials.com/hotlink-ok/photos/heart.jpg);
         background-repeat: no-repeat;
         background-position: left bottom;
      }
      .four{
         width:21em;
         height:17em;
         border:medium solid lightseagreen;
         border-radius: 0.3em;

         background-image:url(https://enjoytutorials.com/hotlink-ok/photos/heart.jpg);
         background-repeat: no-repeat;
         background-position: center top;
      }
      .five{
         width:21em;
         height:17em;
         border:medium solid lightseagreen;
         border-radius: 0.3em;

         background-image:url(https://enjoytutorials.com/hotlink-ok/photos/heart.jpg);
         background-repeat: no-repeat;
         background-position: center center;
      }
      .six{
         width:21em;
         height:17em;
         border:medium solid lightseagreen;
         border-radius: 0.3em;

         background-image:url(https://enjoytutorials.com/hotlink-ok/photos/heart.jpg);
         background-repeat: no-repeat;
         background-position: center bottom;
      }
      .seven{
         width:21em;
         height:17em;
         border:medium solid lightseagreen;
         border-radius: 0.3em;

         background-image:url(https://enjoytutorials.com/hotlink-ok/photos/heart.jpg);
         background-repeat: no-repeat;
         background-position: right top;
      }
      .eight{
         width:21em;
         height:17em;
         border:medium solid lightseagreen;
         border-radius: 0.3em;

         background-image:url(https://enjoytutorials.com/hotlink-ok/photos/heart.jpg);
         background-repeat: no-repeat;
         background-position: right center;
      }
      .nine{
         width:21em;
         height:17em;
         border:medium solid lightseagreen;
         border-radius: 0.3em;

         background-image:url(https://enjoytutorials.com/hotlink-ok/photos/heart.jpg);
         background-repeat: no-repeat;
         background-position: right bottom;
      }
      
      h1{
         color: red;
           
      }
 
              
            
!

JS

              
                
              
            
!
999px

Console