Hi folks,
Static asset compilation has long been a pain point for edx-platform. While we have officially adopted webpack as our path forward and are using it for newer work, the bulk of static asset processing still happens in Django. There's been a lot cruft that's accumulated over the years -- redundant copies of files, symlink hacks to make testing work, etc. I recently wrote up an audit of what happens during asset compilation today:
Our long term goal is to be able to see front end changes in under a second during development, and to be able to do a full prod-ready compilation of static assets for the LMS and Studio in under thirty seconds. We're clearly a long way from that now.
The first step that we're taking is to remove some of the cruft and duplication in the existing static pipeline. The goal is to make things faster and smaller without fundamentally changing the steps in the build process. Once we've cleared that out of the way, we're going to sketch out more concrete plans for porting over existing functionality piece by piece. There will be no big-bang rewrite. Python likely won't ever fully go away, since we need a way to include assets from installed Django apps and XBlocks, but it will play a much smaller role.
You can track the work that we're doing at:
The Slack channel for this work is #assetpipeline
If you would like to be a reviewer for some of this work, please ping me in the Slack channel. I'm especially looking for folks that use theming extensively and/or develop their own custom XBlocks that aren't bundled by default.
Thank you!
Dave