angularjs - Using bower_components with Grunt -


i created simple data listing app using angular js. used bower , grunt. grunt serve project specific port. have error.. when i'm serve project grunt, bower_components not working. mean jquery , angular parts 404. here attach link project.

get project here - https://github.com/chanakade/demoapp

first clone it, "npm install" , "bower install". please tell me how make them work. 404 errors http://localhost:1701/bower_components/jquery/dist/jquery.js 404

enter image description here

you're specifying ./src root of server in gruntfile. unfortunately, bower installs it's dependencies folder above it, in root of project. html has couple of script tags ../bower_components/[path files], not work.

you need try install bower dependencies in src folder. add .bowerrc file in root of project following content:

{   "directory" : "src/bower_components" } 

then reinstall bower dependencies doing:

$ bower install 

check if folder bower_components have been created in src folder.

next replace ../bower_components bower_components in index.html file.


Comments

Popular posts from this blog

Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.12:test (default-test) on project.Error occurred in starting fork -

windows - Debug iNetMgr.exe unhandle exception System.Management.Automation.CmdletInvocationException -

configurationsection - activeMq-5.13.3 setup configurations for wildfly 10.0.0 -