0

刚开始学Grunt,遇到很多问题,我用的是Express和Angular,我的项目目录如下

|-server
  |-controllers
  |-routes
  |-models
  |-views
    |-users
      signin.jade
      signup.jade
    index.jade  //Index of server

|-public
  |-images
  |-javascripts
    |-controllers
    |-services
    |-directives
    app.coffee
  |-stylesheets
    app.scss
  |-views //Angularjs templates

gruntfile.js  
server.js

index.jade的大概如下

//- css, will use cdn files in production
link(href='bower_cmps/normalize-css/....')
link(href='bower_cmps/bootstrap/....')
link(href='stylesheets/app.css')

//- body
.container
  .row
    ...

//- scripts, will use cdn files in production
script(src='bower_cmps/jquery/...')
script(src='bower_cmps/angular/...')
script(src='bower_cmps/angular-ui-router/...')

script(src='javascripts/app.js')
script(src='javascripts/controllers/**.js')
script(src='javascripts/services/**.js')

coffeescript用来写客户端js,scss用来写css

Grunt开发配置是什么样的?

以及如何使用usemin来构建生产文件?

感谢您提供提示

4

1 回答 1

1

你熟悉约曼吗?有一堆 Angular + Express 生成器,看看generator-angular-fullstack

于 2014-04-19T21:22:33.863 回答