New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

dev server Cannot GET '/' after changing assetsRoot #98

plantvsbirds opened this Issue Apr 28, 2016 · 6 comments


None yet
6 participants

plantvsbirds commented Apr 28, 2016

I tried to change build config and make the project build to different directory(out of project's root directory). Soon after that, I found out that npm run dev no longer works and returns cannot get '/'.

I managed to solve this by setting assetsSubDirectory, assetsPublicPath, assetsRoot specifically for dev environment(and make to read from it, overwriting the base setting. It's kind of confusing that even in dev environment build system reads stuff from
Would it be better if these dev settings come with the teamplate? I can input a quick PR.

@plantvsbirds plantvsbirds changed the title from Cannot GET '/' after changing assetsRoot to dev server Cannot GET '/' after changing assetsRoot Apr 28, 2016


This comment has been minimized.

rayzang8 commented May 3, 2016

I met the same issue(file issue #103), and I modify the default configuraion to solve it.


This comment has been minimized.


chrisvfritz commented May 16, 2016

@plantvsbirds I'd be open to taking a look at a PR with what you have in mind.


This comment has been minimized.


chrisvfritz commented Jun 4, 2016

Haven't heard any reports of this problem for a while, so closing for now - happy to reopen pending new reports or especially a proposed PR that would resolve it. 😄

@chrisvfritz chrisvfritz closed this Jun 4, 2016


This comment has been minimized.

runarhk commented Jun 8, 2016

Experienced same problem. Wanted to use output for an Apache Cordova app running on android. Had to change the assetsPublicPath from '/' to '' to get it running on android device. But when I did this, it would no longer work on dev server. The solution was to fix it like explained in issue #103 . Should the config support two different assetsPublicPaths out of the box?


This comment has been minimized.

yupferris commented Jun 13, 2016

@chrisvfritz: I've also run into this problem, and like @runarhk, I was able to fix it as explained by @rayzang8 in #103. The explanation there might not be a PR, but it's pretty close :)

In either case, this still seems to be a problem, and at least one of these tickets should be re-opened until it's resolved.


This comment has been minimized.

hekigan commented Jul 5, 2016

Actually I have a related issue.

I am completely fine developing in the root directory when in dev environment.
Problem arise when the production folder is in a sub (ex:

The biggest issue I have right now is the fonts.
The css are parsed with postcss (which is fine), but the utils.js that has the generateLoaders function kind of prevents me to easily add other plugins to postcss.

My goal was to use something like postcss-fontpath to fix the path issue.
In the current situation I can not have a relative path for my fonts. It's always relative to the root folder whatever I do.

Basically it would be great to have the possibility to have all assets relative to the current folder, or being able to specify the absolute path to set in prod environment. One or the other would solve my problem I think.

Anyone else with this kind of problem?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment