For CSS and Javascript things are a bit different. CSS and SCSS is handled by a PHP SASS compiler.
JavaScript can’t be compiled by PHP so webpack is used for compilation. This also means that you have to ship your plugin with the JavaScript already build.
So no, that’s not possible, you have to precompile it with storefront:build
there’s no javascript PHP compiler supporting modules.
So no, you’ll have to use Webpack (development template) and it won’t change in the near future.
well, I’m a little confused.
Actually bin/build-storefront.sh does work to compile my Javascript-Plugin, but the question is whether it is a coincidence that this works in the production environment or should it also work from the shopware side. In other words, this will always work in the future?
This script uses npm and nodejs - so if your production environment hast both installed, it will work. Normally you won’t finde nodejs or npm on production environments.