Skip to content
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

chore(storefront): STRF-6720 Update jQuery to 3.4.1 #1502

merged 1 commit into from
May 22, 2019

chore(storefront): STRF-6720 Update jQuery to 3.4.1 #1502

merged 1 commit into from
May 22, 2019


Copy link


Update jQuery version to latest.

Tickets / Documentation

Add links to any relevant tickets and documentation.

Copy link

Now that many of these selectors have made their way into modern browsers, it’s almost time to say goodbye to Sizzle. But in order to remove Sizzle in jQuery 4.0, we will also need to remove what we refer to as positional selectors, which are non-standard selectors.
Specifically, jQuery 3.4.0 is deprecating :first, :last, :eq, :even, :odd, :lt, :gt, and :nth. When we remove Sizzle, we’ll replace it with a small wrapper around querySelectorAll, and it would be almost impossible to reimplement these selectors without a larger selector engine.
We think this trade-off is worth it. Keep in mind we will still support the positional methods, such as .first, .last, and .eq. Anything you can do with positional selectors, you can do with positional methods instead. They perform better anyway.

  • :first
  • :last
  • :eq
  • :even
  • :odd
  • :lt
  • :gt
  • :nth

Line 42 of common/select-option-plugin.js:

const $elementNowAtPreviousIndex = selectElement.find(option:eq(${previousIndex}));

const $elementNowAtPreviousIndex = selectElement.find('option').eq(previousIndex);

Copy link
Contributor Author

Thanks for the callout @sacr3dc0w ! We'll update.

Copy link

bigbot commented May 21, 2019

Autotagging @bigcommerce/storefront-team @davidchin

Copy link

sandeepgraju commented May 22, 2019

💚 smoke tested manually without util bump. looks good

will also monitor automated tests on staging before including this in next cornerstone release

@bookernath bookernath merged commit 347e8cf into bigcommerce:master May 22, 2019
@bookernath bookernath deleted the jq-3.4.1 branch May 22, 2019 19:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
None yet
None yet

Successfully merging this pull request may close these issues.

None yet

6 participants