Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
As said here : https://www.drupal.org/node/2655142#comment-12170581, and as doostinharrell responded, I'm created this issue to talk about the use of bower in the stater kit.
The 2 packages its call and install are available through npm. Furthermore, as bower is now in maintenance stage only, and foundation leaving its use in its package to use npm instead (https://github.com/zurb/foundation-zurb-template/blob/master/package.json) .
I propose to remove the bower install, and use the package.json instead.
Comments
Comment #2
HongPong CreditAttribution: HongPong at kor group commentedI support this +1 . If we can patch and test it I will put it in.
Comment #3
doostinharrell CreditAttribution: doostinharrell as a volunteer and at Blue Oak Interactive commented@HongPong I'm working on a patch now. I will hit you back once it is ready to review.
Comment #4
doostinharrell CreditAttribution: doostinharrell as a volunteer and at Blue Oak Interactive commentedComment #5
HongPong CreditAttribution: HongPong at kor group commentedAlso if D7.x gets a foundation 6.x branch I think the same thing should be done, dumping bower, i noted here #2656046: Zurb's Foundation 6 for Drupal 7. thanks doostinharrell :)
Comment #6
doostinharrell CreditAttribution: doostinharrell as a volunteer and at Blue Oak Interactive commentedAttached is a patch that moves dependencies from bower.json to package.json as well as path updates.
Comment #7
doostinharrell CreditAttribution: doostinharrell as a volunteer and at Blue Oak Interactive commentedComment #8
HongPong CreditAttribution: HongPong at kor group commentedIt went up to 6.4.1 so I think we should probably shift up to that sooner or later. However there are enough breaking changes it is probably another task to test everything. See https://github.com/zurb/foundation-sites/releases/ for the notes on 6.4.0 updates.
If this was done here, then #2895757: STARTER installs outdated version of Foundation (6.3.1 to 6.4.1) would be moot.
Comment #9
doostinharrell CreditAttribution: doostinharrell as a volunteer and at Blue Oak Interactive commentedYea, if I had more time today I would have updated to 6.4.1 and tested everything. I haven't had a chance to review the changelog to see if any of the UI patterns have been updated etc so I elected to keep the versions the same to avoid any breaking changes. But yes getting XY Grid into this project should definitely be a priority.
I may be able to make some time on Monday to test and update accordingly.
Comment #10
HongPong CreditAttribution: HongPong at kor group commentedMakes sense. Let's put that stuff on the other thread since it's more complicated. If someone else can test this then I can roll it in and we get done with bower on this branch.
Edit ... also readme.txt should be updated in the same patch, it has a lot of bower references. I can probably do this.
Comment #11
doostinharrell CreditAttribution: doostinharrell as a volunteer and at Blue Oak Interactive commentedHi @HongPong thanks for catching that.
The attached patch should cover all of the necessary updates to the readme files. I also removed the .bowerrc files.
Comment #12
doostinharrell CreditAttribution: doostinharrell as a volunteer and at Blue Oak Interactive commentedDrush sub-theme creation was completing however there was an error regarding the bower.json as drush_op was trying to replace content in a file that didn't exist. This has been resolved in the latest patch.
Comment #13
doostinharrell CreditAttribution: doostinharrell as a volunteer and at Blue Oak Interactive commentedAlright more progress...
As part of this new attached patch I have also addressed issue #2895757 and updated to Foundation 6.4.1. This includes updates to both zurb_foundation and STARTER to use Float Grid by default. I also added some additional documentation to STARTER.scss explaining how disabling Float Grid in favor or XY Grid would also mean they have to migrate base theme templates to their sub theme to rework markup for XY Grid compatibility.
Comment #14
serg2 CreditAttribution: serg2 commentedDo we still install 6.3.1 in starter for compatibility or is this this an oversight?
Comment #15
doostinharrell CreditAttribution: doostinharrell as a volunteer and at Blue Oak Interactive commentedYes @serg2 that was an oversight. This why we perform peer review. Thanks!
Comment #16
HongPong CreditAttribution: HongPong at kor group commentedI would suggest that we stick with 6.3.1 on this issue and get that locked in first. (some are set to 6.3.1 and some 6.4.1 on the latest patch #5 here) Note the patch is +2MB because it covers this.
Really even, we could remove bower and put this on the next tagged release, since it will make the theme easier to develop from, but put the shift to 6.4.1 onto the release after that one ( #2895757: STARTER installs outdated version of Foundation (6.3.1 to 6.4.1) ) . It is better not to roll issues that are somewhat separate on the same issue/patch.
Comment #17
doostinharrell CreditAttribution: doostinharrell as a volunteer and at Blue Oak Interactive commentedSounds good to me. Let's see if someone can review/test patch #3 then we can close this task out.
Comment #18
serg2 CreditAttribution: serg2 commentedTested zurb_foundation--remove-bower-and-use-npm-instead--2895755-3.patch
It works just as before but skips the requirement for bower, just as the IS required.
Comment #20
HongPong CreditAttribution: HongPong at kor group commentedLooks good and is now in 8.x-6.x - thank you doostinharrell, serg2, FlorisMoriceau ! I am switching this to 7.x-5.x if anyone wants to submit a patch for that branch, or we can close this as fixed.
I think this will help with adoption a lot because bower was a sticking point for a lot of people :)
Comment #21
HongPong CreditAttribution: HongPong at kor group commentedComment #22
doostinharrell CreditAttribution: doostinharrell as a volunteer and at Blue Oak Interactive commentedComment #23
doostinharrell CreditAttribution: doostinharrell as a volunteer and at Blue Oak Interactive commented