-
Notifications
You must be signed in to change notification settings - Fork 11
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
Try @wordpress/scripts #358
base: develop
Are you sure you want to change the base?
Conversation
@@ -6,33 +6,35 @@ let subMenus = []; | |||
// if menu has lost focus inadvertently, restore it | |||
const setupFocusTrap = () => { | |||
const lastMenuItem = pageHeader.querySelector('.mobile-menu > ul > li:last-of-type'); | |||
const menuItemClassList = `.${Array.from(lastMenuItem.classList).join('.')}`; | |||
let previousFocus; | |||
if ( lastMenuItem ) { |
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.
This is kind of an unrelated change, but I was getting a scripting error since this was undefined in my test setup.
@@ -114,7 +114,8 @@ class DisplayAuthor extends Component { | |||
|
|||
api | |||
.getPostsFromAuthors(requestArguments, value) | |||
.then((data = [], i, xhr) => { // eslint-disable-line | |||
.then((data = [], i, xhr) => { |
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.
These changes were the result of running yarn lint --fix
.
e8dff12
to
4e1d2d8
Compare
This PR migrates the build scripts to
@wordpress/scripts
to compile the theme as is. The idea is to simplify the build configuration, and provide an incremental change to allowing the blocks to be upgraded.Ref: #285
Steps to test:
cd private
rm -rf node_modules
yarn && yarn build
Considerations:
I think the main benefit to this PR is it cuts down on the projects development dependencies. But if you do go ahead with moving the blocks to a separate plugin in the near term, then maybe this PR is not as relevant or useful.