Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

JavaScript

Anthony Candaele
seal-mask
.a{fill-rule:evenodd;}techdegree
Anthony Candaele
Full Stack JavaScript Techdegree Student 32,135 Points

React.createElememt is not a function

I downloaded the project files (the folder 'scoreboard') and entered the code:

const title = React.createElememt( 'h1', { id: 'main-title', title: 'this is a title' }, 'My First React Element' );

console.log(title);

Then I started the local dev server of Visual Studio Code, but when I look in the console, I see this error message:

"Uncaught TypeError: React.createElememt is not a function"

not sure wat the problem is. Can someone help me?

thanks,

Anthony

2 Answers

Looks like just a small typo!

Instead of

React.createElememt

should be

React.createElement