-
Notifications
You must be signed in to change notification settings - Fork 191
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feature: add @wordpress/scripts
build process for GiveWP 3.0
#6862
Conversation
@JasonTheAdams @kjohnson this is ready for review. cc: @ravinderk this is how we'll be handling v3 related form scripts including new gateways. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good work, @jonwaldstein! I had a couple minor questions and one suggestion.
# @wordpress/scripts build directory | ||
build | ||
**/build.* | ||
**/build.asset.* |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should anything be added to the .distignore
file?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think so, I assume we want to keep the build folder for distribution since it contains the generated scripts.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah, the /build
folder probably needs to be included in the distribution, instead of trying to mess with moving that target directory.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@jonwaldstein For sure! I'm really thinking about if there are any specific files (file maps?) within the build that shouldn't be included in distribution.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Gotchya, it appears wp scripts does not generate those file maps so we should be good. If anything looks weird during distribution we can add to the distignore.
@JasonTheAdams ready for re-review |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great work, @jonwaldstein! Nice to have this done for the merge!
Description
This adds
@wordpress/scripts
for building our v3 forms related scripts. The entry point for these scripts are inwepback.config.js
.Affects
This only affects new scripts being added to
wepback.config.js
Visuals
N/A
Testing Instructions
npm run dev:v3
npm run build:v3
npm run watch:v3
npm run build
runs both mix and wp-scripts for productionPre-review Checklist
@unreleased
tags included in DocBlocks