Argento custom js
Notice
This tutorial assumes that you already created custom theme based on one of Argento themes.
If you did not — go ahead, it will take 15 minutes.
Argento brings possibility to create new argento-custom.js
file, that will be
automatically included on all pages.
-
Create new directory in yout custom Argento sub-theme:
app/design/frontend/Local/argento-[essence|flat]-custom/web/js
- Create
argento-custom.js
insidejs
folder -
Add script skeleton:
define([ 'jquery', 'domReady!' ], function($) { alert("Hi, I'm custom js file"); });
-
Save the file and run following bash commands to deploy script
cd magento/root/folder php bin/magento setup:static-content:deploy