Skip to main content
InterviewHubPRO
Section Overview
Q374

Question 374 of 407

Part 9: React Hooks Deep Dive (262 - 316)

92%
React Core & Hooks (407 Qs)•Part 9: React Hooks Deep Dive (262 - 316)

How to use class field declarations syntax in React classes?

junior LevelHooks

React Class Components can be made much more concise using class field declarations. You can initialize state and class properties directly as class fields without a constructor: