课程: JavaScript Essential Training
今天就学习课程吧!
今天就开通帐号,24,600 门业界名师课程任您挑!
Challenge intro: Create elements
- [Instructor] In this challenge, you'll create new DOM elements and populate them with content, specifically a navigation menu with a list of links. In the challenge code, an existing DOM has been set up for you, but it's happening behind the scenes, so you can't get direct access to it in the browser and take a look at it. That DOM contains a header element with the class siteheader and that's where you'll append the new menu. You also have a JavaScript template literal containing list items that will be used in the navigation menu. So you can just append this list of items into an unordered list as you go along. Your task is to add the list items to an unordered list, then add the unordered list to a nav container. Then give the nav container the class .main-navigation and finally append the new nav container to the existing element with the class .siteheader. The final HTML of your nav element should follow…
随堂练习,边学边练
下载课堂讲义。学练结合,紧跟进度,轻松巩固知识。
内容
-
-
-
-
-
-
-
DOM: The Document Object Model4 分钟 7 秒
-
(已锁定)
Access elements with querySelector methods6 分钟 6 秒
-
(已锁定)
Access elements using older methods3 分钟 45 秒
-
(已锁定)
Practice: Find an element1 分钟 29 秒
-
(已锁定)
Modifying element classes4 分钟 53 秒
-
(已锁定)
Attributes4 分钟 13 秒
-
(已锁定)
Inline style3 分钟 52 秒
-
(已锁定)
Practice: Modify classes and attributes, and styles1 分钟 36 秒
-
(已锁定)
Add DOM elements5 分钟 25 秒
-
(已锁定)
Challenge intro: Create elements1 分钟 17 秒
-
(已锁定)
Solution: Create elements3 分钟 35 秒
-
-
-
-
-
-
-