React lets you build user interfaces out of individual pieces called components. Create your own React components like Thumbnail, LikeButton, and Video. Then combine them into entire screens, pages, and apps.
How to reproduce it
export class ComponentClass extends Component {
render() {
return (
<>
<h1>Class component</h1>
<a href='#'>Link</a>
</>
);
}
}
Error
The href attribute requires a valid value to be accessible. Provide a valid, navigable address as the href value. If you cannot provide a valid href, but still need the element to resemble a link, use a button and change it with appropriate styles.
Solution
Use /#
instead of #
.
import { Component } from 'react';
export class ComponentClass extends Component {
render() {
return (
<>
<h1>Class component</h1>
<a href='/#'>Link</a>
</>
);
}
}