Hey everyone! I'm new to using React and I decided to try cloning Netflix by following a tutorial on YouTube. However, I've encountered an issue with rendering an image in a functional component.
The error message I'm receiving is as follows:
InvalidCharacterError: Failed to execute 'createElement' on 'Document': The tag name provided ('/static/media/tab1.fab25bc3.png') is not a valid name.
This is the code for my Functional Component:
import React, { Component } from "react";
import Img from "../images/tab1.png";
export default function TabContentOne() {
return (
<div className="container">
<div className="tab-content">
<span>
If you decide Gamolytcs isn't for you - no problem. No commitment.
Cancel online anytime.
<br />
<button>Try it now</button>
<Img src={Img} alt="" />
</span>
</div>
</div>
);
}