From the course: JavaScript Code Challenges: Creating Web Apps

Unlock this course with a free trial

Join today to access over 25,300 courses taught by industry experts.

Overview of the necessary JavaScript concepts

Overview of the necessary JavaScript concepts - JavaScript Tutorial

From the course: JavaScript Code Challenges: Creating Web Apps

Overview of the necessary JavaScript concepts

- [Instructor] We're in the middle of building a live code editor where users can type HTML, CSS, or JavaScripts and instantly see the results. It's like your own mini code pen. By now, you've already seen most of the core JavaScript ideas for web in action. But here are a couple of final concepts we're spotlighting. We're using an iframe for the live preview. To update it, we access the iframe's contentDocument and use doc.write() to inject new content into it. This gives us an isolated little environment to display whatever the user types. And because developers deserve comfort, we'll add a dark mode option. All it takes is a checkbox and a bit of CSS class toggling. It's actually a small detail, but it makes a big difference in a fancy or editor seems. All of this is super practical. And when you're done, you can try building this editor in that editor, and then in that editor you can build another editor because we all love inception. Alright, that's an overview of the concepts…

Contents