property ‘marquee’ does not exist on type ‘jsx.intrinsicelements’

    Recently, I was developing an SPFX client-side web part using React JS. In that webpart, I was adding a react component into the existing react component, but the react application showed me an error:

    Property welcome does not exist on type ‘JSX.IntrinsicElements’

    property 'marquee' does not exist on type 'jsx.intrinsicelements'

    Property ‘marquee’ does not exist on type ‘jsx.intrinsicelements’.

    The error was coming because I was writing in a small letter.

    Actually, when we are developing a component using react we should start with a capital letter, the class name.

    import * as React from 'react';
    import { IWelcomeProps } from "./IWelcomeProps";
    export default class Welcome extends React.Component<IWelcomeProps>
    {
        public render():JSX.Element{
            return(
                <h1>{this.props.message}</h1>
            )
        }
    }

    Also, while importing the react component, we should give the capital letter like the below:

     <Welcome message={this.props.message} /> :null} 

    Here, we learned how to solve the property, and then the property name does not exist of type ‘JSX.IntrinsicElements’ in the SPFX react client-side part.

    You will be able to solve the below errors after following the above solution:

    • property ‘div’ does not exist on type ‘jsx.intrinsicelements’.
    • property ‘marquee’ does not exist on type ‘jsx.intrinsicelements’.ts(2339)
    • property ‘img’ does not exist on type ‘jsx.intrinsicelements’

    You may also like;

    comment_count comments
    Oldest
    Newest
    Oldest

    Comment as a guest:

    >