topical media & game development

talk show tell print

mobile-query-three-www-jsinside-tutorial.htm / htm



  <!DOCTYPE html>
  <html lang="en">
    <head>
      <meta charset="utf-8">
      <title>Render loop and Animation</title>
      <meta name="description" content="">
      <meta name="author" content="">
      <base target="_blank">
  
      <!-- Le HTML5 shim, for IE6-8 support of HTML elements -->
      <!--[if lt IE 9]>
        <script src="http://html5shim.googlecode.com/svn/trunk/html5.js"></script>
      <![endif]-->
  
      <!-- Le styles -->
          <link href="../vendor/bootstrap/docs/assets/css/bootstrap.css" rel="stylesheet">
          <link href="../vendor/bootstrap/docs/assets/js/google-code-prettify/prettify.css" rel="stylesheet">
          <link href="./bootstrap-srcannotate.css" rel="stylesheet">
      <style>
        body {
          padding-top: 60px; /* 60px to make the container go all the way to the bottom of the topbar */
        }
      </style>
  
      <!-- Le fav and touch icons -->
      <link rel="shortcut icon" href="images/favicon.ico">
      <link rel="apple-touch-icon" href="images/apple-touch-icon.png">
      <link rel="apple-touch-icon" sizes="72x72" href="images/apple-touch-icon-72x72.png">
      <link rel="apple-touch-icon" sizes="114x114" href="images/apple-touch-icon-114x114.png">
    </head>
  
    <body>
  
      <div class="navbar navbar-fixed-top">
        <div class="navbar-inner">
          <div class="container">
            <a class="btn btn-navbar" data-toggle="collapse" data-target=".nav-collapse">
              <span class="icon-bar"></span>
              <span class="icon-bar"></span>
              <span class="icon-bar"></span>
            </a>
            <a class="brand" href="#">tQuery</a>
            <div class="nav-collapse">
              <ul class="nav">
              </ul>
            </div><!--/.nav-collapse --> 
          </div>
        </div>
      </div>
          <div class="container">
                  <div class="row">
                          <div class="span7" data-markdown>
  
# This is a title Here you can see how cool this is it </div> <div class="span5"> </div> </div>

          </div> <!-- /container -->
  
          <!-- Le javascript
          ================================================== -->
          <!-- Placed at the end of the document so the pages load faster -->
          <script src="../vendor/bootstrap/docs/assets/js/jquery.js"></script>
          <script src="../vendor/bootstrap/docs/assets/js/google-code-prettify/prettify.js"></script>
          <script src="../vendor/bootstrap/docs/assets/js/bootstrap-transition.js"></script>
          <script src="../vendor/bootstrap/docs/assets/js/bootstrap-alert.js"></script>
          <script src="../vendor/bootstrap/docs/assets/js/bootstrap-modal.js"></script>
          <script src="../vendor/bootstrap/docs/assets/js/bootstrap-dropdown.js"></script>
          <script src="../vendor/bootstrap/docs/assets/js/bootstrap-scrollspy.js"></script>
          <script src="../vendor/bootstrap/docs/assets/js/bootstrap-tab.js"></script>
          <script src="../vendor/bootstrap/docs/assets/js/bootstrap-tooltip.js"></script>
          <script src="../vendor/bootstrap/docs/assets/js/bootstrap-popover.js"></script>
          <script src="../vendor/bootstrap/docs/assets/js/bootstrap-button.js"></script>
          <script src="../vendor/bootstrap/docs/assets/js/bootstrap-collapse.js"></script>
          <script src="../vendor/bootstrap/docs/assets/js/bootstrap-carousel.js"></script>
          <script src="../vendor/bootstrap/docs/assets/js/bootstrap-typeahead.js"></script>
          <script src="./bootstrap-srcannotate.js"></script>
          <script>
          // ==UserScript==
          // @name Use Markdown, sometimes, in your HTML.
          //
author: Paul Irish <paulirish.com/> // gray http://git.io/data-markdown // @match * // ==/UserScript== // If you're not using this as a userscript just delete from this line up. It's cool, homey. (function markdownSlideToHtml(){ if (!window.Showdown){ var script = document.createElement('script'); script.onload = markdownSlideToHtml; script.src = 'raw.github.com/github/github-flavored-markdown/gh-pages/scripts/showdown.js'; document.body.appendChild(script); return; } [].forEach.call(document.querySelectorAll('[data-markdown]'), function fn(elem){ // strip leading whitespace so it isn't evaluated as code //var text = elem.textContent.replace(/\n\s*\n/g,'\n'); // jerome- to have better support of html within markdown var text = elem.innerHTML; //console.log("origin innerHTML", text.split('\n')); // remove all blanks lines //text = text.replace(/\n\s*\n/g,'\n'); //console.log("step text", text) // set indentation level so your markdown can be indented within your HTML var matches = text.match(/^\n([ \t]*)/); var leadingws = matches[1].length; //console.log("first line", matches) //console.log("leadingws", leadingws) var regex = new RegExp('\\n[ \\t]{' + leadingws + '}','g'); var md = text.replace(regex,'\n'); //console.log("pre md", md); html = (new Showdown.converter()).makeHtml(md); //console.log("post html", html); // to support prettyprint html = html.replace(/<code><br \/>/g,'<pre class="prettyprint">'); html = html.replace(/<br \/><\/code>/g,'</pre>'); // unescape [><] html = html.replace(/&amp;gt;/g,'>'); html = html.replace(/&amp;lt;/g,'<'); //console.log("escaped html", html); // here, have sum HTML elem.innerHTML = html; }); // callback prettyprint to highlight code found in markdown prettyPrint(); }()); </script> </body> </html>


(C) Æliens 04/09/2009

You may not copy or print any of this material without explicit permission of the author or the publisher. In case of other copyright issues, contact the author.