Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

J_shelfwood's avatar

Hosting Vue JS project, 'no input file specified' on reload

Hey guys,

I've created a website for a client. I've built a Vue JS application for him with quasar framework ( https://quasar-framework.org/ ). Problem is that now I've deployed it it seems to work fine except for when I reload the page using cmd + r. Then it says no input file specified on a blank page.

So this is the link for example "http://vueproject.com/home" and when pressing cmd+r it shows "no input file specified".

What I managed to find out is that when I change the url to http://vueproject.com/#/home it works out fine. What are my options here?

How can I get the # sign back in every link so reloading works correctly? Is there a way to make it so that the /#/ prepend isn't necessary?

0 likes
4 replies
tykus's avatar

You need to redirect all HTTP traffic to the same index page so the at the Vue application can be started, and Vue Router take over routing. We can achieve this in Laravel by catching all URIs and returning the same view template which contains the Vue app - I don't know how to do the same thing in Quasar, or if you would need to configure your web server to redirect all traffic to the same index page.

For information, this is an example of a Laravel way:

Route::any('{any?}', function () {
    return view('index');
})->where('any', '.*');

The Vue Router docs show you some configuration options for different web servers to handle the redirection there.

J_shelfwood's avatar

Is there a way I can do this without a laravel project? I'm hosting it on Laravel Forge as a Static HTML project. I'm using quasar framework to generate the application. I don't see any way in Forge to configure anything that catches all URL's and points them to the index.html

2 likes
jaec86's avatar
jaec86
Best Answer
Level 7

Laravel Forge by default looks for index.php in the root directory, so you need to change it to look for index.html. You can edit the nginx config file yourself in forge, at the end of the "app" section there is a "files" button. You should replace:

location / {
    try_files $uri $uri/ /index.php?$query_string;
}

for the following:

location / {
    try_files $uri $uri/ /index.html;
}

I'm currently using this configuration and it's working. Let me know if it worked for you.

10 likes

Please or to participate in this conversation.