-
Notifications
You must be signed in to change notification settings - Fork 23
Load Ecommerce Components via vendor directory instead of js package #1515
Load Ecommerce Components via vendor directory instead of js package #1515
Conversation
… via the ecommerce js build
Bluehost Brand Plugin
|
||||||||||||||||||||||||||||
| Project |
Bluehost Brand Plugin
|
| Branch Review |
try/loading-ecommerce-module-components-directly
|
| Run status |
|
| Run duration | 32m 16s |
| Commit |
|
| Committer | Evan Mullins |
| View all properties for this run ↗︎ | |
| Test results | |
|---|---|
|
|
0
|
|
|
3
|
|
|
33
|
|
|
0
|
|
|
407
|
| View all changes introduced in this branch ↗︎ | |
Bluehost Brand Plugin
|
||||||||||||||||||||||||||||||||||||||||||||||||||||
| Project |
Bluehost Brand Plugin
|
| Branch Review |
try/loading-ecommerce-module-components-directly
|
| Run status |
|
| Run duration | 35m 18s |
| Commit |
|
| Committer | Evan Mullins |
| View all properties for this run ↗︎ | |
| Test results | |
|---|---|
|
|
1
|
|
|
3
|
|
|
33
|
|
|
0
|
|
|
406
|
| View all changes introduced in this branch ↗︎ | |
Tests for review
vendor/newfold-labs/wp-module-solutions/tests/cypress/integration/solutions-app.cy.js • 1 failed test
| Test | Artifacts | |
|---|---|---|
| My Plugins and Tools in Plugin App > My Plugins & Tools displays with Solution |
Test Replay
Screenshots
Video
|
|
vendor/newfold-labs/wp-module-coming-soon/tests/cypress/integration/coming-soon-woo.cy.js • 1 flaky test
| Test | Artifacts | |
|---|---|---|
| Coming Soon with WooCommerce > Replace our admin bar site status badge with WooCommerce's when active |
Test Replay
Screenshots
Video
|
|
vendor/newfold-labs/wp-module-onboarding/tests/cypress/integration/2-general-onboarding-flow/basic-info.cy.js • 1 flaky test
| Test | Artifacts | |
|---|---|---|
| Basic Info Page > Check Drawer Activity |
Test Replay
Screenshots
Video
|
|
vendor/newfold-labs/wp-module-onboarding/tests/cypress/integration/3-ecommerce-onboarding-flow/basic-info.cy.js • 1 flaky test
| Test | Artifacts | |
|---|---|---|
| Basic Info Page > Check Drawer Activity |
Test Replay
Screenshots
Video
|
|
|
|
This feels especially doable since the ecommerce module already loads the build file on the plugin app screen. See: https://github.com/newfold-labs/wp-module-ecommerce/blob/trunk/includes/ECommerce.php#L372-L383 The index is currently ignored in git, but I'm adding it back now. This should make things pretty easy to sidestep needing an e-commerce package at all. 🎉 |
…nents-directly * release/3.16.0: (23 commits) update to latest ecommerce and facebook modules revert to wp-scripts 27 and remove react-jsx-runtime polyfill adjust polyfill path and remove from normal webpack config happy lint happy life add jsx-runtime-polyfill for wp6.5 support - remove unused package bump installer version in composer to match lock update htaccess-manager package to fix 7.3 issue in php add missing package according to lint update version to 3.16.0 Composer(deps): Bump newfold-labs/wp-module-onboarding NPM Dev(deps-dev): Bump @tailwindcss/forms from 0.5.9 to 0.5.10 NPM(deps): Bump @wordpress/icons from 10.15.1 to 10.16.0 NPM(deps): Bump @wordpress/dom-ready from 4.14.0 to 4.16.0 Composer(deps): Bump newfold-labs/wp-module-coming-soon update remaining modules for runtime updates use latest fully released packages update to latest runtime and ecommerce module add @newfold packaged to tailwind config NPM Dev(deps-dev): Bump @wordpress/env from 10.14.0 to 10.16.0 update to runtime 1.1.3 release ... # Conflicts: # package-lock.json # package.json # src/app/pages/ecommerce/page.js # src/app/pages/home/freeAddonsSection.js # src/app/pages/home/index.js # src/app/pages/home/welcomeSection.js
…irectly * develop: allow cypress matrix 60 min
…irectly * develop: NPM(deps): Bump react-router-dom from 7.1.1 to 7.1.3 # Conflicts: # package-lock.json
|
Before merging this we may want to have a larger discussion about best practices and module architecture. If we want to update this one to be more in line with the others, we should make sure we're following a best practice. I've also had discussions about updating the plugin app to use slots and slotfills for modules to add components into assigned places, but I think we'd need some considerable updates to get to a place we can do this. |
|
Will take care of this update in the new repository at https://github.com/newfold-labs/wp-plugin-bluehost |
Proposed changes
This changes how the e-commerce module components are loaded in the plugin app. Before they were loaded via a package, but this updates it to directly load them in the plugin app like we do for other modules. We load the js components directly from the module in the vendor directory. This will need considerable testing on live sites.
This would eliminate the need for a js build package in the e-commerce module.
We'd also want to restructure the module and move the components out of the src directory and into a top-level components dir (src directories are usually excluded from builds). This effort is to bring all modules to a more consistent architecture.
Open Discussion
Is there a reason I'm missing that the build step is still required for the e-commerce module components? Removing it would simplify the plugin release process and make more of the modules lend components to the plugin rather than require a composer and npm package to run.
Type of Change
Checklist
Further comments