cssAudio - Activefile-genericCSS - ActiveGeneric - ActiveHTML - ActiveImage - ActiveJS - ActiveSVG - ActiveText - Activefile-genericVideo - ActiveLovehtmlicon-new-collectionicon-personicon-teamlog-outoctocatpop-outspinnerstartv

Pen Settings

CSS Base

Vendor Prefixing

Add External Stylesheets/Pens

Any URL's added here will be added as <link>s in order, and before the CSS in the editor. If you link to another Pen, it will include the CSS from that Pen. If the preprocessor matches, it will attempt to combine them before processing.

Quick-add: + add another resource

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.

Quick-add: + add another resource

Code Indentation

     

Save Automatically?

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.

            
              <div class="container-fluid">
  <div class="row topLine">
    <div class="col-sm-5">
      <h1> Emmet Dojo:</h1>
    </div>
    <div class="col-sm-7">
      <button type="button" class="btn btn-danger float-right" onClick="clearContents()">CLEAR</button>
    </div>
  </div>
  <textarea class="form-control" rows="10" id="emmetT" placeholder="Instructions: type emmet expressions (consult Syntax, Examples and HTML below) + tab"></textarea>

  <div class="row">
    <br />
    <div class="col-sm-4">
      <h3>Syntax :</h3>
      <div class="well pre-scrollable columnA">
        <ul class="list-unstyled">
          <li>Child: <kbd>></kbd></li>
          <li>Sibling: <kbd>+</kbd></li>
          <li>Climb-up: <kbd>^</kbd></li>
          <li>Multiplication: <kbd>*</kbd></li>
          <li>Grouping: <kbd>()</kbd></li>
          <li>Id: <kbd>elem#</kbd></li>
          <li>Class: <kbd>elem.</kbd></li>
          <li>Custom attributes: <kbd>[attr]</kbd></li>
          <li>Item numbering: <kbd>$</kbd></li>
          <li>Text: <kbd>{}</kbd></li>
        </ul>
      </div>

    </div>

    <div class="col-sm-4">
      <h3>Examples :</h3>
      <div class="well pre-scrollable columnB">
        <ul class="list-unstyled">
          <li>nav>ul>li</li>

          <li>div+p+bq</li>
          <li>div+div>p>span+em^bq</li>
          <li>div+div>p>span+em^^^bq</li>
          <li>ul>li*5</li>
          <li>div>(header>ul>li*2>a)+footer>p</li>
          <li>(div>dl>(dt+dd)*3)+footer>p</li>
          <li>div#header</li>
          <li>div.class1</li>
          <li>div#footer.class1.class2.class3</li>
          <li>td[title="Hello world!" colspan=3]</li>
          <li>ul>li.item$*5</li>
          <li>ul>li.item$$$*5</li>
          <li>ul>li.item$@-*5</li>
          <li>ul>li.item$@3*5</li>
          <li>ul>li.item$@-3*5</li>
          <li>a{Click me}</li>
        </ul>
      </div>
    </div>

    <div class="col-sm-4">
      <h3>HTML :</h3>
      <div class="well pre-scrollable columnC">
        <ul class="list-unstyled">
          <li><kbd>!</kbd> html:5</li>
          <li><kbd>a:link</kbd> </li>
          <li><kbd>br</kbd></li>
          <li><kbd>link:css</kbd></li>
          <li><kbd>form:post</kbd></li>
          <li><kbd>btn</kbd></li>
          <li><kbd>lorem</kbd></li>
        </ul>
      </div>
    </div>
  </div>
  <div class="panel panel-default">
  <div class="panel-body">
    Official Emmet site: <a href="http://emmet.io" target="_blank">emmet.io</a>&nbsp;&nbsp;&nbsp;
<a href="http://docs.emmet.io/cheat-sheet/" target="_blank">Cheat Sheet</a>
  </div>
</div>
  </div>
</div>
            
          
!
            
              body{
  background-color:#222;
/*   padding:10px; */
}

h1{
color: cornflowerBlue;
  margin:0;
}

h3, h5{
color: cornflowerBlue;
}

.topLine{
  margin-bottom:10px;
}

.columnA{
  height:200px;
  max-height: 200px;
/*   min-width: 240px; */
  font-size:16px;
}

.columnB{
  height:200px;
  max-height: 200px;
/*   min-width: 300px; */
  font-size:15px;
}
.columnB ul{
  margin-left:-10px;
}

.columnC{
  height:200px;
  max-height: 200px;
  padding-left:10px;
  font-size:16px;
}

.btn-danger{
  margin-top:6px;
}

textarea{
  margin-bottom:-30px;
}


            
          
!
            
              // Magic Sauce:
// https://github.com/emmetio/textarea
// Only HTML for now


emmet.require('textarea').setup({
    pretty_break: true, // enable formatted line breaks (when inserting 
                        // between opening and closing tag) 
    use_tab: true       // expand abbreviations by Tab key
});

function clearContents(){
  document.getElementById("emmetT").value = '';
}


            
          
!
999px
Loading ..................

Console