Content breakdown before / Magento bundling enables
Really sucks: 4.830 MB of JS
Install Magento Extension
composer require creativestyle/magesuite-magepack
bin/magento setup:upgrade --keep-generated
bin/magento setup:di:compile
bin/magento config:set dev/js/enable_magepack_js_bundling 1
bin/magento config:set dev/js/enable_js_bundling 0
Install node.
# Debian/Ubuntu
curl -sL https://deb.nodesource.com/setup_12.x | sudo -E bash -
#Centos
curl -sL https://rpm.nodesource.com/setup_10.x | sudo bash -
sudo yum install nodejs
Only NodeJS can save Magento from the fiasco.
Install Mage Pack
sudo npm install -g magepack --unsafe-perm=true --allow-root
if You are on centos you will suffer. I can't without the pain with Magento2.
If you having error while loading shared libraries: libXcomposite.so.1: cannot open shared object file
Run:
sudo yum install pango.x86_64 libXcomposite.x86_64 libXcursor.x86_64 libXdamage.x86_64 libXext.x86_64 libXi.x86_64 libXtst.x86_64 cups-libs.x86_64 libXScrnSaver.x86_64 libXrandr.x86_64 GConf2.x86_64 alsa-lib.x86_64 atk.x86_64 gtk3.x86_64 -y
Run generate
magepack generate --cms-url="9CMS_PAGE_URL9" --category-url="9CATEGORY_PAGE_URL9" --product-url="9PRODUCT_PAGE_URL9"
Run bundle
magepack bundle
Clear magento cache
bin/magento c:C
Result Content Brake Down
Top comments (0)