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 JavaScript Basics (Retired) Introducing JavaScript Your First JavaScript Program

Ilhyun Jo
Ilhyun Jo
6,288 Points

I did exactly what the instructor did but when I clicked the preview button a new tab appeared but nothing happened.

I wrote alert("Hello"); document.write("<h1>Hello"); and there wasn't an alert or anything written in the new tab.

7 Answers

Restart the browser/tab. Or choose an other browser. Usually it works, but I also had some JS problems with chrome

Ilhyun Jo
Ilhyun Jo
6,288 Points

Thanks I changed to safari and it works. Not sure why it doesn't work on chrome.

jason chan
jason chan
31,009 Points

Clear browser history or icognito. Cache is developers number 1 enemy! You'll see it networking, everywhere. LOLs.

There are way too many questions revolving around the same problem. Treehouse, the bug is 99% likely to be on your end. Let us know when you've resolved it.

Clovis Shropshire
Clovis Shropshire
7,139 Points

Exactly. On the other hand, it did work for me on Windows Chrome, just not on Mac version.

Raphael Reiter
Raphael Reiter
6,820 Points

I tried on Chrome, doesn't work. cleared history, doesn't work. tried on safari, still nothing....

Brandon Schabell
Brandon Schabell
3,846 Points

I've had this issue on a number of Treehouse courses. I believe there is a delay between saving and the actual remaking of the preview webpage. Save, wait 60 seconds, then try to preview it again. It seems to get worse during peak hours.

Clovis Shropshire
Clovis Shropshire
7,139 Points

I agree with Brandon. Seems to be working fine now.