Javascript 第一次ng后的角度停止包括在释放模式中

Javascript 第一次ng后的角度停止包括在释放模式中,javascript,angularjs,gruntjs,release-mode,Javascript,Angularjs,Gruntjs,Release Mode,我正在使用yeoman/generator grunt angular系统编译一个angular应用程序,我对该系统进行了轻微修改,以适应与另一个应用程序共享的代码。“发布模式”是将所有模板编译成javascript,以便立即加载所有内容。如果我引用一个模板,如下所示: <div ng-include="'components/navbar/navbar.html'" /> <div class="row"> <div class="large-4 column

我正在使用yeoman/generator grunt angular系统编译一个angular应用程序,我对该系统进行了轻微修改,以适应与另一个应用程序共享的代码。“发布模式”是将所有模板编译成javascript,以便立即加载所有内容。如果我引用一个模板,如下所示:

<div ng-include="'components/navbar/navbar.html'" />
<div class="row">
  <div class="large-4 columns">
    <h3>Your Courses</h3>
    <div ng-include="'components/courses/course-list.html'" ng-controller="MyCoursesCtrl" />
    <form id="fileupload" 
          data-url="http://api.orienteer.io/upload_gpx"
          method="POST" enctype="multipart/form-data" 
          data-ng-controller="GpxFileUploadCtrl" 
          ng-submit="alert('gooo');">
      <span class="btn btn-success fileinput-button"  ng-class="{disabled: disabled}">
        <i class="glyphicon glyphicon-plus"></i>
        <span>Upload a GPX File</span>
        <input type="file" name="gpx_file" ng-disabled="disabled">
        {{ status }}
      </span>
    </form>
  </div>
</div>

基于聊天:切换到更完整的UI路由器实现可能会解决与ng include指令明显不兼容的问题

我今天正在检查这个问题,我记得在这个问题上使用了不同的符号

他们使用:

<div ng-include="'myUsers_Form.htm'"></div>

而不是:

<div ng-include="'myUsers_Form.htm'" />


当我将第一个include更改为您的样式时,我遇到了与该样式之后的include相同的问题,但在W3使用的符号中,可能会包含多个文件。

angular的哪个版本?@markthethomas-1.3.4还添加了my bower.json中的dependencies子句,这应该可以回答任何其他依赖性问题。真奇怪。所以你没有从控制台得到任何错误?有什么相关的吗?使用file://路径时,Ng include有时会很麻烦。另外:当你说“开发”模式时,这意味着你正在使用什么工具在本地为应用程序提供服务w/?(我看到你在使用yeoman,但我不熟悉该规范生成器)我刚刚将发布模式代码推到。没有任何东西是缩小的,所以你应该能够阅读所有的东西。直到现在你都没有注意到那个指令是自动关闭的。抢手货有人能向我解释一下从DOM的角度来看,自动关闭和非自动关闭标记之间的区别吗?编辑:这是一个开始。虽然切换到更全面地使用ui路由器通常是一个好主意,@Casper成功了!很高兴它成功了!可能与指令如何匹配有关(基于标记、元素和c)。很高兴它能工作!
<div ng-include="'myUsers_Form.htm'" />