Code Block Examples

Default Abilities with MDX

Take a look at the following block of code.. We will take a look after the page builds.

Javascript: The language of the web

(function() {

var cache = {};
var form = $('form');
var minified = true;

var dependencies = {};

var treeURL = 'https://api.github.com/repos/PrismJS/prism/git/trees/gh-pages?recursive=1';
var treePromise = new Promise(function(resolve) {
  $u.xhr({
    url: treeURL,
    callback: function(xhr) {
      if (xhr.status < 400) {
        resolve(JSON.parse(xhr.responseText).tree);
      }
    }
  });
});

Markup (HTML): The structure of the web

<div class="somethin-dumb">
  <p>Something dumb</p>
</div>

CSS: The style of the web

.somethin-dumb {
  color: red;
}
  • Check out this link for more information.

  • Also here's an image of minified javascript

code-block-examples-image-1