Title: componentWillMount and friends deprecated from React · Issue #373 · hyperstack-org/hyperstack · GitHub
Open Graph Title: componentWillMount and friends deprecated from React · Issue #373 · hyperstack-org/hyperstack
X Title: componentWillMount and friends deprecated from React · Issue #373 · hyperstack-org/hyperstack
Description: componentWillMount (before_mount callback), componentWillUpdate (before_update callback), componentWillReceiveProps (before_new_params callback) have been deprecated. Here is the plan to replace the first two: before_mount The before_mou...
Open Graph Description: componentWillMount (before_mount callback), componentWillUpdate (before_update callback), componentWillReceiveProps (before_new_params callback) have been deprecated. Here is the plan to replace th...
X Description: componentWillMount (before_mount callback), componentWillUpdate (before_update callback), componentWillReceiveProps (before_new_params callback) have been deprecated. Here is the plan to replace th...
Opengraph URL: https://github.com/hyperstack-org/hyperstack/issues/373
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"componentWillMount and friends deprecated from React","articleBody":"componentWillMount (before_mount callback), componentWillUpdate (before_update callback), componentWillReceiveProps (before_new_params callback) have been deprecated.\r\n\r\nHere is the plan to replace the first two:\r\n\r\n### `before_mount`\r\n\r\nThe before_mount callback can be implemented as part of the render_wrapper method, so the callbacks get called just before calling the application render method. \r\n\r\n### `before_update`\r\n\r\nThe before_update callback can be implemented the same as before_mount, however, React did pass the \"old-state\" and \"new-state\" values to the callback. This notion is meaningless in Hyperstack, but there possibly could be code around that is using the lower level \"props\" and is depending on the old-state and new-state. \r\n\r\nSo for now we will use the react UNSAFE_componentWillUpdate callback (which gives no warning, but implements the legacy behavior, then in the callback we will check if the proc is receiving any parameters, and if so publish a deprecation notice that in the future these parameters will NOT be passed.\r\n\r\nThen at some future release, the code will use the same mechanism as before_mount (i.e. it's just part of the render wrapper)\r\n\r\n### `before_new_params`\r\n\r\nThis is sort of being replaced by a static (read class level) call back called `getDerivedStateFromProps` but the whole thing is probably unnecessary in hyperstack since the hyper-state component manages state changes to avoid rerenders (which is the base reason for this being replaced.)\r\n\r\nSo we will just deprecate this method.\r\n\r\n\r\n","author":{"url":"https://github.com/catmando","@type":"Person","name":"catmando"},"datePublished":"2021-03-10T16:50:50.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":0},"url":"https://github.com/373/hyperstack/issues/373"}
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:0627e738-aba3-3eb3-515a-df60c2d4a21b |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | BEAC:1F80F:272C6C2:3205B45:6991BB85 |
| html-safe-nonce | c79834253f37d85a847f910f941705a5f15fecd69a4b5c65a8919741046ba4a9 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJCRUFDOjFGODBGOjI3MkM2QzI6MzIwNUI0NTo2OTkxQkI4NSIsInZpc2l0b3JfaWQiOiI0MzY4MDY3NTU1MjQ5NzMyNDg1IiwicmVnaW9uX2VkZ2UiOiJpYWQiLCJyZWdpb25fcmVuZGVyIjoiaWFkIn0= |
| visitor-hmac | a118a5bfad7750e6d0d2af42b112dc0446a2e0f3ba4342f8f3fa4308f326cd05 |
| hovercard-subject-tag | issue:828033316 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/hyperstack-org/hyperstack/373/issue_layout |
| twitter:image | https://opengraph.githubassets.com/255b0edff43b0070a2aa8c65109983f0132b9604b14c6a116fc57f3b60c37225/hyperstack-org/hyperstack/issues/373 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/255b0edff43b0070a2aa8c65109983f0132b9604b14c6a116fc57f3b60c37225/hyperstack-org/hyperstack/issues/373 |
| og:image:alt | componentWillMount (before_mount callback), componentWillUpdate (before_update callback), componentWillReceiveProps (before_new_params callback) have been deprecated. Here is the plan to replace th... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | catmando |
| hostname | github.com |
| expected-hostname | github.com |
| None | 42c603b9d642c4a9065a51770f75e5e27132fef0e858607f5c9cb7e422831a7b |
| turbo-cache-control | no-preview |
| go-import | github.com/hyperstack-org/hyperstack git https://github.com/hyperstack-org/hyperstack.git |
| octolytics-dimension-user_id | 34562730 |
| octolytics-dimension-user_login | hyperstack-org |
| octolytics-dimension-repository_id | 145879576 |
| octolytics-dimension-repository_nwo | hyperstack-org/hyperstack |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 145879576 |
| octolytics-dimension-repository_network_root_nwo | hyperstack-org/hyperstack |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 848bc6032dcc93a9a7301dcc3f379a72ba13b96e |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width