title: Code works in jsfiddle but not in html document. Why?
body: <p>I am trying to create a sapui5 table from xml view but it doesn't seem to be working when I run it from visual studio but when I run it in jsfiddle it runs just fine. What is the reason for this?</p>
  
  <p>Here is the code in my xmlTest.hml:</p>
  
  <pre><code>&lt;!DOCTYPE html&gt;
  &lt;html&gt;
  &lt;head&gt;
      &lt;script src="https://openui5.hana.ondemand.com/resources/sap-ui-core.js" id="sap-ui-bootstrap" data-sap-ui-theme="sap_bluecrystal" data-sap-ui-libs="sap.ui.commons,sap.ui.table"&gt;&lt;/script&gt;
      &lt;meta charset="utf-8"&gt;
      &lt;title&gt;JS Bin&lt;/title&gt;
  &lt;/head&gt;
  
  &lt;body class="sapUiBody" id="content"&gt;
  
      &lt;script id="view1" type="ui5/xmlview"&gt;
          &lt;core:view xmlns:core="sap.ui.core"
                     xmlns="sap.ui.commons"
                     xmlns:table="sap.ui.table"
                     xmlns:html="http://www.w3.org/1999/xhtml"
                     controllername="view.Main"&gt;
              &lt;table:table width="100%" visiblerowcount="5" selectionmode="Single" editable="false" rows="{/data}"&gt;
                  &lt;table:title&gt;&lt;label text="XML View"&gt;&lt;/label&gt;&lt;/table:title&gt;
                  &lt;table:column&gt;
                      &lt;label text="Row Num" /&gt;
                      &lt;table:template&gt;&lt;textfield value="{rowNum}"&gt;&lt;/textfield&gt;&lt;/table:template&gt;
                  &lt;/table:column&gt;
                  &lt;table:column&gt;
                      &lt;label text="ID" /&gt;
                      &lt;table:template&gt;&lt;textfield value="{id}"&gt;&lt;/textfield&gt;&lt;/table:template&gt;
                  &lt;/table:column&gt;
                  &lt;table:column&gt;
                      &lt;label text="First Name" /&gt;
                      &lt;table:template&gt;&lt;textfield value="{name}"&gt;&lt;/textfield&gt;&lt;/table:template&gt;
                  &lt;/table:column&gt;
                  &lt;table:column&gt;
                      &lt;label text="Email Address" /&gt;
                      &lt;table:template&gt;&lt;textfield value="{email}"&gt;&lt;/textfield&gt;&lt;/table:template&gt;
                  &lt;/table:column&gt;
  
              &lt;/table:table&gt;
          &lt;/core:view&gt;
      &lt;/script&gt;
      &lt;script type="text/javascript"&gt;
          var aData = [
          { rowNum: 1, id: 42, name: "Anthony", email: "anthony@example.com" },
          { rowNum: 1, id: 42, name: "Anthony", email: "anthony@example.com" },
          { rowNum: 1, id: 42, name: "Anthony", email: "anthony@example.com" },
          ];
          sap.ui.controller("view.Main", {
              doSomething: function (oEvent) { }
          });
  
          var oView = sap.ui.xmlview({
              viewContent: jQuery("#view1").html()
          });
          var oModel = new sap.ui.model.json.JSONModel({
              data: aData
          });
          oView.setModel(oModel);
          oView.placeAt("content");
      &lt;/script&gt;
  &lt;/body&gt;
  &lt;/html&gt;
  </code></pre>
  
  <p>Running this code from visual studio I get the following errors:</p>
  
  <p><img src="https://i.stack.imgur.com/UMCRw.png" alt="enter image description here"></p>
  
  <p>These errors refer to <a href="https://openui5.hana.ondemand.com/resources/sap/ui/table/table.js" rel="nofollow noreferrer">this file</a>.</p>
  
  <p>When I copy my code into jsfiddle it works just fine. Here is my <a href="http://jsfiddle.net/Anthony1/yauw6mw8/1/" rel="nofollow noreferrer">jsfiddle</a>.</p>