Link to home
Create AccountLog in
Avatar of James Hancock
James HancockFlag for United States of America

asked on

When does VScode javascript and XAMP apache not update in the browser?

Hi

For my Javascript Phaser game dev, my XAMP server has been working fine. But, sometimes in the morning, when I begin my work, changes I make to my javascript in VSCODE change the file,  in my htdocs xamp folder, also, but don't get served to my browser updated. They stay as the previous file, even after a refresh, or a new browser window! Yesterday, restarting my apache in the XAMP control panel seemed to solve this, but this morning, restarts aren't refreshing in the browser to the newly updated files.

Has anybody seen this behavior before? What can I do? I am so close to finished, that this is frustrating :) Javascript is an amazing language. I revived my dead/abandoned  Unity project to life in no time. C# was okay, but I'd never go back, now, unless no option. I can do game object setup as well as the Unity IDE in javascript code. No loss.

In my VSCODE, there is a yellow lightbulb next to the line that is a console log that doesn't update

console.log("create -!- answer = "+answer);

Open in new window


Thanks

ASKER CERTIFIED SOLUTION
Avatar of lenamtl
lenamtl
Flag of Canada image

Link to home
membership
Create a free account to see this answer
Signing up is free and takes 30 seconds. No credit card required.
See answer
Avatar of James Hancock

ASKER

Thanks


How can I do this in Javascript code? All the pages I find seem to offer HTML code as a solution. Is that the only way?


Is this a Phaser problem?

It is a browser/web server problem.  In many cases you want the web browser to cache as much as possible. You can set the web server to NOT cache something .. So if you change something and want to see the changes in your browser you have to FORCE a reload CTRL-F5