yeoman

Yeoman, Grunt, AngularJS and error 404 on POST form

与世无争的帅哥 提交于 2019-12-13 07:37:45
问题 I am trying to send a form with "POST" method with AngularJS. I use $http to send it but it always return "Cannot POST" and 404 error. The route is correct and only happens if I execute my app via Grunt (sending by "GET" works perfect). The app has been built using Yeoman. I think that it has to be a silly problem but I cannot make it work. The view: <form name="formLogin" ng-submit="login()"> <ul> <li> <label for="user">User</label> <input type="text" id="user" name="user" ng-model="user"> <

Missing modules after fresh generation with Yeoman's angular-fullstack

旧城冷巷雨未停 提交于 2019-12-13 05:39:52
问题 So, I generated a fresh angular-fullstack with TypeScript, MongoDB, Bootstrap, Bootstrap UI, Authentication Boilerplate, Twitter and Google OAuth, Grunt, Jasmine, HTML, CSS, and UI-Router for the settings. After I ran npm install and bower install. There were some unmet dependencies, so I installed TypeScript, locally Mocha, locally Tslint, locally Also, I was getting an error during build that was resolved by installing grunt-babel@5.0.0, locally. Now, when I run "grunt serve" It all works

grunt build Aborted due to warning “Destination not written because minified HTML was empty” and “Parse Error:”

巧了我就是萌 提交于 2019-12-13 02:59:01
问题 I am using Yeoman (http://yeoman.io/) and I usually just run grunt build in order to minify and upload my AngularJS app to the server. However for some reason I am getting a >> Destination not written because minified HTML was empty. I haven't had this trouble before until now and I have not changed my Grunt file. It seems as though everything else is getting minifies just fine, even the other html files within the same /views directory. I read on this thread (grunt serve: concurrent:server

Errors while running Grunt build for the first time

做~自己de王妃 提交于 2019-12-12 12:25:50
问题 I created an angularJS project using Yeoman Previewing the app using grunt serve works well. The server starts and I can browse my pages successfully. When executing grunt build I am getting Running "cdnify:dist" (cdnify) task Going through dist/404.html, dist/index.html to update script refs >> No "cssmin" targets found. Warning: Task "cssmin" failed. Use --force to continue. Aborted due to warnings. Which I dont know how to fix, or how to begin. Am I missing some configurations?

How to prevent yeoman from sending anonymous statistics?

百般思念 提交于 2019-12-12 11:18:02
问题 When the message came up about whether to send anonymous information, I accidentally hit the enter key defaulting to "yes". Now everytime I reinstall/fully remove then install node/yo or execute the yo command, it no longer asks. Is there some file or setting that is hidden in the filesystem that I can manually change such that I do not send anonymous usage statistics to yeoman? is there a configuration file or setting? It is unsettling to know that my usage statistics may be sent while I do

Deploy AngularJS app on tomcat

六眼飞鱼酱① 提交于 2019-12-12 10:36:59
问题 I created an AngularJS app with the yeoman angular generator. Now I want to host it using Apache tomcat. I already ran "grunt build" and have all my assets ready in the "dist"-folder. Is there a way to create a .war-file or can I just copy the files to a folder inside tomcat? 回答1: Just copy paste your all files in your project folder e.g. $TOMCAT_PATH/webapps/your-project-root/ Cheers!! 来源: https://stackoverflow.com/questions/33785665/deploy-angularjs-app-on-tomcat

Grunt watch tasks seem to take a very long time

本小妞迷上赌 提交于 2019-12-12 10:36:42
问题 I'm running two simple tasks that run for <100ms each but when run under the watch command the two combined tasks are taking ~8 seconds in total (there seems to be an overhead of 3.5 seconds per task). I'm using it with live-reload for development and I'm finding it very frustrating. I tried setting spawn to false but this seemed to break it and none of the associated tasks were run. Here's sample output from when a sass file is changed. >> File "app/styles/main.scss" changed. File "app

How do I change the path for generated files for the generator-angular in yeoman

陌路散爱 提交于 2019-12-12 09:59:13
问题 My question: From the readme on https://github.com/yeoman/generator-angular yo angular:controller user Produces app/scripts/controllers/user.js How do I make it produce app/js/controllers/user.js What I've looked at: I don't think I can configure the path since the source shows that the path is hard codded: Generator.prototype.createControllerFiles = function createControllerFiles() { this.appTemplate('controller', 'scripts/controllers/' + this.name); this.testTemplate('spec/controller',

Repeating Prompts with a Yeoman Generator

江枫思渺然 提交于 2019-12-12 09:18:13
问题 I am creating a Yeoman Generator to automate creation of few database tables. I need to provide users with a prompt to add multiple columns (combination of ColumnName and DataType below). I have a template saved in my disk where I bind the dynamic names from the user inputs and based upon this template, the final script is generated by the Yeoman Generator. Can you suggest how to prompt user to enter repetitive combinations of ColumnName/DataType he wants to enter? var prompts = [{ type:

Yeoman CSS image paths

吃可爱长大的小学妹 提交于 2019-12-12 08:56:39
问题 When I build my Yeoman project (nothing special, I'm only using jQuery and Modernizr), the images used with CSS aren't shown. My CSS-code .contact { background:url(../icon-contact.png) no-repeat top center; } Output after building the app (no difference) .contact {background:url(../icon-contact.png) no-repeat top center;} This doesn't work because the filename of icon-contact.png has changed to f91724e0.icon-contact.png . How can I make sure that the image-paths are updated in the minified