4

I've changed a JavaScript file in Magento but changes are not reflected. I also cleared the cache but nothing changed.

So if anyone know why please help me.

Thank you.

1
  • php bin/magento setup:static-content:deploy -f Feb 21, 2018 at 11:19

3 Answers 3

2

Css and js files are stored in pub/static/areaname(frontend)/thememodule/theme folder.

you have to manually delete the respective js/css to reflect your changes.

Or you can run php bin/magento setup:static-content:deploy command.

2
  1. Enable developer mode: php bin/magento deploy:mode:set developer.
  2. Clean pub/static/frontend directory.
  3. Run php bin/magento dev:source-theme:deploy (This command creates 'symlinks' for less, js files).
  4. Clean cache.
0

Please run below command

  php bin/magento setup:static-content:deploy -f 

-f is for forcefully deployment, if it does not auto deploy.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.