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

[3.0] Remove deprecated code #3336

Closed
9 tasks done
ryanflorence opened this issue Apr 16, 2016 · 10 comments
Closed
9 tasks done

[3.0] Remove deprecated code #3336

ryanflorence opened this issue Apr 16, 2016 · 10 comments
Milestone

Comments

@ryanflorence
Copy link
Member

ryanflorence commented Apr 16, 2016

This issue tracks the things that need to be deprecated. I'd like to have an issue for each one of these. Also, moving forward, when we deprecate an API, we need to immediately make an issue and assign it to the milestone when we are going to completely remove it.

Here's the list, please edit and add anything I'm missing.

  • context.location, context.history
  • default hashHistory
  • old histories that don't use useRouterHistory
  • mixins
  • Link props (query, params, etc)
  • getComponents first argument
  • useRoute (the warning says to use createTransitionManager but I don't think that's right, seems like they should use useRouterHistorybut I don't know the history of that warning, transitionManager seems like implementation, not API)
  • isActive(pathname, query, indexOnly) in createTransitionManager and ``replaceState(state, pathname, query)inrunTransitionHooks`
  • Multiple leave hooks

After we cut our next minor release (https://github.com/reactjs/react-router/milestones/next-2.3.0), we'll create a 3.0 branch to start working on this stuff, that way we can still make bug fix releases on 2.3 from master. To keep our promise to not make major releases more often than every 3 months, we can release 3.0 on May 9-ish.

@ryanflorence ryanflorence added this to the next-3.0.0 milestone Apr 16, 2016
@timdorr
Copy link
Member

timdorr commented Apr 18, 2016

Set up a 2.x branch that we can put stuff on after 3.0 is out. I don't think we need ones for 2.0.x, 2.1.x, 2.2.x, etc.

In order to avoid the hassles and confused issues while we waited on 2.0, we should keep master as 2.x until we're either at or near a 3.0.0 release. It's more annoying for us as developers, but it's also annoying having to close tons of issues because of confusion over docs and code changes.

@taion
Copy link
Contributor

taion commented Apr 18, 2016

The next major release should go on a rolling next branch (like the one we have). That way you don't have to remember to keep updating .travis.yml (or the Circle equivalent, because Circle is sort of just a lot better) with the branch config.

In practice it's not that confusing to users (since only people close enough to the code to actually follow the repo will see it), and it's less book-keeping for us.

If we're really ambitious, we could just set up the deprecation removals on that branch right now, and cut pre-releases on an ongoing basis.

@timdorr
Copy link
Member

timdorr commented Apr 18, 2016

Working on that at the moment. Updated the next branch too.

@timdorr
Copy link
Member

timdorr commented Apr 18, 2016

Re: The getComponents deprecation. That was introduced in 2.2. You guys are closer to this issue than I am, but I remember Ryan (or someone else) saying anything un-deprecated that works in 2.0 will work in 3.0 with warnings. Are we attempting to maintain that here? Honestly, I don't care. I just want to know if it should go into the PR or not.

(P.S. Yes, @taion, CircleCI is many times better than Travis. I've got to talk Dan into using it for Redux. The speedups over there would be quite notable.)

@timdorr
Copy link
Member

timdorr commented Apr 18, 2016

OK, they're all in #3340.

@timdorr
Copy link
Member

timdorr commented Apr 18, 2016

Found some more. Added to the OP. But it's bedtime, so if someone else wants to get them, go nuts!

@taion
Copy link
Contributor

taion commented Apr 18, 2016

@timdorr The rule of thumb is that stuff that people use a lot should stay deprecated for longer. The location arg to getComponent is almost never used, so we don't need to keep it around.

@taion
Copy link
Contributor

taion commented Apr 18, 2016

BTW, lets go with merging between next and master rather than rebasing. It makes for a slightly messier git history, but it'll be easier to tell what's going on.

@ryanflorence
Copy link
Member Author

ryanflorence commented Apr 18, 2016

@timdorr The rule of thumb

Probably need to document this somewhere.

Rule is: Deprecated API goes away in the next release, unless we decide it's too close to the next release and we want to give people more time.

Sound right @taion ?

@taion
Copy link
Contributor

taion commented Apr 18, 2016

That makes sense to me.

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

No branches or pull requests

3 participants