AngularJS + sails.js

前端 未结 5 1303
有刺的猬
有刺的猬 2020-12-07 08:12

I am developing an app that can utilize sails.js for back-end and AngularJS for Front-end. I thought that I\'ll create an Angular App using Yeoman-angular generator https://

5条回答
  •  既然无缘
    2020-12-07 08:49

    Since Sails is a purely back-end framework and Angular is purely front-end, they can work together nicely. It can get a little confusing when you bring the Angular generator into it, but here are the basic steps if you were to start with the Angular Seed app and Sails v0.10:

    1. Create a new Sails app with sails new myApp
    2. Wipe out the contents of the myApp/assets folder
    3. Copy the contents of the Angular Seed app folder into myApp/assets
    4. Replace the contents of myapp/views/layout.ejs with those of the Angular Seed app/index.html file
    5. Cut all of the non-script tag content from the layout.ejs file (everything after the tag and before the first
提交回复
热议问题