javascript icon indicating copy to clipboard operation
javascript copied to clipboard

[guide] [react] add note about deprecated lifecycles

Open meetzaveri opened this issue 7 years ago • 7 comments

There were still deprecated lifecycle being mentioned in two places. Thus by removing them, it will make clear sense of latest React API after 16.2.

meetzaveri avatar Jan 16 '19 07:01 meetzaveri

These are not actually "deprecated" in the sense that they'll only be "unsafe with async rendering".

This makes sense. But can we like address developer that this lifecycles are now no more in use like by adding a label in parenthesis or making seperate section for it ?

meetzaveri avatar Jan 16 '19 07:01 meetzaveri

I think a section for it that calls out that only in React 16.3+, certain methods should be avoided in favor of others, would be useful, yes.

ljharb avatar Jan 16 '19 08:01 ljharb

Okay. So should I make changes now in readme file acc. to it?

meetzaveri avatar Jan 17 '19 03:01 meetzaveri

Updating this PR to do that would be great!

ljharb avatar Jan 17 '19 07:01 ljharb

Sure. So should I finally add a section about avoiding lifecycles?

meetzaveri avatar Jan 17 '19 18:01 meetzaveri

Not avoiding; but using the ones appropriate for your React version. Not everyone is on the latest version.

ljharb avatar Jan 18 '19 08:01 ljharb

There were still deprecated lifecycle being mentioned in two places. so by removing them, it will make clear sense of latest React API after 16.2.

MDASI avatar Dec 31 '21 10:12 MDASI