Consider the below statement – Which method will be used at the place of blank space (____)?

38. Consider the below statement – Which method will be used at the place of blank space (____)?

class MainTitle extends React.Component {
  ______ {
    return <h1>Welcome at IncludeHelp!</h1>;
  }
}
  1. renderDOM()
  2. renderComponent()
  3. render()
  4. render()

Answer: C) render()

Explanation:

The correct code is:

class MainTitle extends React.Component {
  render() {
    return <h1>Welcome at IncludeHelp!</h1>;
  }
}

Comments and Discussions!

Load comments ↻






Copyright © 2024 www.includehelp.com. All rights reserved.