Search code examples
shopwareshopware6

JS building Error caused by Shopware Paypal Module


since I installed the SwagPayPal module via composer I am getting the following error when building the storefront using build-storefront.sh:

ERROR in /var/www/html/content/web/vendor/store.shopware.com/swagpaypal/src/Resources/app/storefront/src/swag-paypal.abstract-buttons.js
Module not found: Error: Can't resolve '@paypal/paypal-js' in '/var/www/html/content/web/vendor/store.shopware.com/swagpaypal/src/Resources/app/storefront/src'

Does anybody know what causes this and how to fix this?


Solution

  • In a shell navigate to /var/www/html/content/web/vendor/store.shopware.com/swagpaypal/src/Resources/app/storefront/src and run

    npm install
    

    Then try building the storefront again.