Problem/Motivation
Varbase 11 used to get six front-end libraries by running scripts/drupal-libraries-sync.js, a Node script that copied files out of node_modules/ into web/libraries/, driven by a drupal-libraries block plus six npm dependencies and a postinstall hook in package.json. That is replaced by Composer packages on Packagist, each required by the module or the varbase_* recipe that actually loads it: vardot/aos 2.3.4, vardot/jquery.fancytree 2.38.5, vardot/ckeditor5-media-embed-drupal 47.6.2, vardot/ace 1.44.0 and vardot/dropzone 5.9.3 (all type: drupal-library, all on Packagist), plus swagger-api/swagger-ui, which drupal/openapi_ui_swagger already required and which only needed an installer path.
This project still carries scripts/drupal-libraries-sync.js (112 lines). This copy was already dead before the Composer move: .gitlab-ci.yml has no job that runs it, and the repository has no package.json at all, so nothing carries the drupal-libraries block the script reads. It is 112 lines of dead code that reads as live wiring.
Steps to reproduce
- Check out the
1.0.xbranch. - Grep the repository for the script:
git grep -n drupal-libraries-sync 1.0.x. The only hit is the script file itself. - Read
.gitlab-ci.yml: no job copies, references or runs it. - Grep every
package.jsonin the repository for adrupal-librariesblock: there is none.
Proposed resolution
Delete scripts/drupal-libraries-sync.js. Nothing in the repository reads it, so this removes dead code and no behaviour.
Verified on a freshly installed Varbase 11.4.5 site in DDEV with the packages resolved from Packagist and no VCS repositories: 14/14 declared library files present, 10/10 assets HTTP 200, 7/7 Drupal libraries discovered with every asset resolving, status report green, and yarn install succeeds with none of the six npm library packages present.
Remaining tasks
- ✅ File an issue
- ✅ Addition/Change/Update/Fix
- ❌ Testing to ensure no regression
- ➖ Automated unit/functional testing coverage
- ➖ Developer Documentation support
- ➖ User Guide Documentation support
- ➖ UX/UI designer responsibilities
- ➖ Accessibility and Readability
- ❌ Reviewed by a human
- ❌ Code review by maintainers
- ❌ Full testing and approval
- ❌ Credit contributors
- ❌ Review with the product owner
- ❌ Update Release Notes
- ❌ Release
User interface changes
- N/A
API changes
- N/A
Data model changes
- N/A
Release notes snippet
- Removed the unused
scripts/drupal-libraries-sync.js. The front-end libraries come from Composer packages required by the modules and recipes that load them.
Issue fork rightup-3620354
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
Comments
Comment #4
rajab natshahComment #5
rajab natshahReleased in rightup 1.0.0-alpha1.
Comment #7
rajab natshah