0

我遵循了本教程: https ://www.npmjs.com/package/gulp-angular-templatecache

我不知道在我的项目中把它放在哪里。在这一点上..

angular.module("templates").run([$templateCache,
 function($templateCache) {
  $templateCache.put("template1.html",
   // template1.html content (escaped) 
  );
  $templateCache.put("template2.html",
   // template2.html content (escaped) 
  );
  // etc. 
 }
]);

作为语法,我不确定应该去哪一部分,我试图明智地遵循本教程

这是我的文件 app.js

angular.module('myapp', ['ionic', 'myapp.controllers', 'myapp.services'])

.run(function($ionicPlatform) {
.
.

我有一个问题,这样做我所有的模板都被修改了吗?因为这是我需要的。谢谢你。

4

1 回答 1

2

在这篇文章中是你要找的东西,我是为我的一个项目做的。

Gulp 部署

于 2016-03-17T00:44:56.190 回答