Skip to content
This repository has been archived by the owner on Sep 6, 2021. It is now read-only.

Update jQuery to v1.9.1 (stable) & include jQuery Migrate #3123

Closed
wants to merge 24 commits into from
Closed

Update jQuery to v1.9.1 (stable) & include jQuery Migrate #3123

wants to merge 24 commits into from

Conversation

TuckerWhitehouse
Copy link
Contributor

As per issue #3072, I have upgraded jQuery from 1.7 to 1.9.1 for both Brackets and the SpecRunner.

See inline comments for specific code decisions.

@@ -83,6 +83,8 @@
define(function Inspector(require, exports, module) {
"use strict";

var InspectorJSON = require("text!LiveDevelopment/Inspector/Inspector.json");
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The old method used $.get, which wouldn't use the correct scope in testing, so I replaced it with a require. I'm not sure if it would have been better to include ExtensionUtils, and utilize the loadFile function?

@njx
Copy link
Contributor

njx commented Mar 13, 2013

Hi @TuckerWhitehouse -- thanks for taking this on. We won't be able to pull this in in this sprint, but we'll schedule some time to try to land it early next sprint, which should be in a couple weeks.

@TuckerWhitehouse
Copy link
Contributor Author

@njx, no problem, i'll make sure to keep testing it with the new updates, and have it working as soon as you start sprint 23.

@njx
Copy link
Contributor

njx commented Mar 13, 2013

One question--is there any need for the shim other than for third-party code like Bootstrap? Ideally we would fix up all the code in Brackets itself so it doesn't rely on the shim.

@TuckerWhitehouse
Copy link
Contributor Author

Just the bootstrap plugins. It's helpful in that it will console.log when you use a deprecated function though.

Edit: and the brackets-concat.js file

@dangoor
Copy link
Contributor

dangoor commented Apr 16, 2013

@TuckerWhitehouse sorry for our delay in getting to this. We were just trying to decide how we wanted to approach a jQuery upgrade given the testing time we'd want to put in. We've decided that the best bet is to upgrade to jQuery 2.0 when the stable version comes out, so that we do the migration and testing once rather than in two steps (1.9->2.0).

I've added a card to the backlog for this.

Your work here is undoubtedly going to be useful when we do make the transition. I'm going to close this pull request for now, but we'd certainly like to pull in your work once 2.0 stabilizes.

@dangoor dangoor closed this Apr 16, 2013
@TuckerWhitehouse
Copy link
Contributor Author

Hey @dangoor, no worries. I'll keep my update_jQuery branch updated (I just swapped in the jQuery-2.0.0-beta3 and it seems to be working great, I think beta3 is the last one before final).

Also, there was already a card on trello (https://trello.com/card/upgrade-jquery/4f90a6d98f77505d7940ce88/813).

As far as including jQuery Migrate, it's only required because of the Bootstrap plugins (which are very out of date as well - the updated plugins in Bootstrap 2 don't need $.browser), so I'm not sure if it would be better at looking into upgrading these plugins or if they are going to be replaced with something else?

@peterflynn peterflynn mentioned this pull request Apr 17, 2013
@dangoor
Copy link
Contributor

dangoor commented Apr 18, 2013

Thanks for noting the Bootstrap plugins in the Trello card. You make a good point, and I think when the time comes to upgrade jQuery we'd probably opt to fix the problem with the plugins one way or another rather than use jQuery Migrate.

@adrocknaphobia
Copy link
Contributor

Are we ready to look at jQuery 2.0?

@TuckerWhitehouse
Copy link
Contributor Author

@adrocknaphobia, my guess is no. There's still a lot that needs to be updated before a clean transition to 2.0 would be possible. To get the ball rolling, i've submitted a pull request (#3665) to remove the deprecated .isResolved & .isRejected which can be done now without impact.

Another item that needs to be pursued is updating the Bootstrap plugins (which at their current version, still rely on $.browser). Edit: #3672

@redmunds
Copy link
Contributor

@TuckerWhitehouse Thanks for all of your effort, so far. We decided to implement the jQuery migration in Sprint 26 (which starts today!). We'll be working off of the Trello card you referred to above (https://trello.com/card/3-upgrade-jquery-less-bootstrap/4f90a6d98f77505d7940ce88/813).

We already merged your pull request (#3665) to remove deprecated functions. Next, we're going to upgrade Bootstrap (#3672) to avoid the need for jQuery Migrate. Then we'll merge your other deprecated functions fixes (#3814).

Please let us know if you want to update this branch to merge after that. That would be awesome. We want to get all of this in early to give it lots of bake time. Thanks again for all of your help.

@njx
Copy link
Contributor

njx commented May 23, 2013

(Also, if you think it would be better to just start fresh rather than basing off this branch, that would be good to know too.)

@TuckerWhitehouse
Copy link
Contributor Author

@redmunds & @njx, I actually have another branch for a clean jQuery 2.0 upgrade [https://github.com/TuckerWhitehouse/brackets/tree/jQuery_2], so i'll just open a new pull request from that branch.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

7 participants