Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

113
Views
Simple react component is not showing up on UI

I have a simple React component like this inside file components/daw/index.js. It should render just a text:

import React from 'react';

export default class Daw extends React.PureComponent {
    constructor(props) {
        super(props);
    }

    render() {
        return (
            <div className="daw-container" key="daw-container">
                <span>DAW placeholder</span>
            </div>
        );
    }
}

I'm using the above component by another React component. Inside the file components/media-viewer/VideoViewer/index.js I have:

export default class VideoViewer extends React.PureComponent {

  render() {
    return (
      <div>
          <Daw/>
      </div>
    );
  }

}

The simple text DAW placeholder is not showing up on UI. Am I missing something obvious? Is something trivial missed?

class Daw extends React.PureComponent {
    constructor(props) {
        super(props);
    }

    render() {
        return (
            <div className="daw-container" key="daw-container">
                <span>DAW placeholder</span>
            </div>
        );
    }
}
class VideoViewer extends React.PureComponent {

  render() {
    return (
      <div>
          <Daw/>
      </div>
    );
  }

}

ReactDOM.render(<VideoViewer />, document.querySelector('.react'));
<script crossorigin src="https://unpkg.com/react@16/umd/react.development.js"></script>
<script crossorigin src="https://unpkg.com/react-dom@16/umd/react-dom.development.js"></script>
<div class='react'></div>

about 4 years ago · Juan Pablo Isaza
1 answers
Answer question

0

The code snippet provided by @CertainPerformance shows that the answer is no. Nothing trivial is missed. The fault is somewhere else in the code.

class Daw extends React.PureComponent {
    constructor(props) {
        super(props);
    }

    render() {
        return (
            <div className="daw-container" key="daw-container">
                <span>DAW placeholder</span>
            </div>
        );
    }
}
class VideoViewer extends React.PureComponent {

  render() {
    return (
      <div>
          <Daw/>
      </div>
    );
  }

}

ReactDOM.render(<VideoViewer />, document.querySelector('.react'));
<script crossorigin src="https://unpkg.com/react@16/umd/react.development.js"></script>
<script crossorigin src="https://unpkg.com/react-dom@16/umd/react-dom.development.js"></script>
<div class='react'></div>

about 4 years ago · Juan Pablo Isaza Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!