简体   繁体   中英

Angular CLI project not working after copying and pasting

I'm new to Angular and over the past few days I've been creating a new project using it. I've used the Angular CLI to create the project and it's been running fine. I've added no additional dependencies or done anything special.

I want to upload my project to GIT, so I copied and pasted the contents of the project folder into another directory. Now when I attempt to run the project it doesn't work - I get the error:

Cannot get /

The project still works in its previous location. I've tried deleting node_modules and doing an npm install but still have the same problem.

I don't know what additional information to provide as I've not been using Angular long.

The comments here by jonrsharpe helped lead me to an answer. The problem isn't with the project itself (as such) but rather the folder/repository itself. Angular will throw the "Cannot get /" error when in a folding containing "%20" in it's name.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM