Skip to content

Commit 895da56

Browse files
authored
reorganized header structure
1 parent 3405dad commit 895da56

File tree

1 file changed

+26
-28
lines changed

1 file changed

+26
-28
lines changed

README.md

+26-28
Original file line numberDiff line numberDiff line change
@@ -13,20 +13,14 @@ Each lesson contains a link to the task itself and may provide several solutions
1313
- [functions and arrow functions](#functions-and-arrow-functions)
1414
- [Event handlers](#event-handlers)
1515
- [`var` and `let`](#var-and-let)
16-
- [Lesson 1 – attaching the event handlers](#lesson-1--attaching-the-event-handlers)
17-
- [Get to the code](#get-to-the-code)
18-
- [Lesson 2 – adding a counter](#lesson-2--adding-a-counter)
19-
- [Get to the code](#get-to-the-code-1)
20-
- [Lesson 3 – improving the counter](#lesson-3--improving-the-counter)
21-
- [Get to the code](#get-to-the-code-2)
22-
- [Lesson 4 – removing the buttons](#lesson-4--removing-the-buttons)
23-
- [Get to the code](#get-to-the-code-3)
24-
- [Lesson 5 – reusability / marker class](#lesson-5--reusability--marker-class)
25-
- [Get to the code](#get-to-the-code-4)
26-
- [Lesson 6 – reusability / only once](#lesson-6--reusability--only-once)
27-
- [Get to the code](#get-to-the-code-5)
28-
- [Lesson 7 – making a jQuery plugin](#lesson-7--making-a-jquery-plugin)
29-
- [Get to the code](#get-to-the-code-6)
16+
- [Chapter one – basics](#chapter-one--basics)
17+
- [Lesson 1 – attaching the event handlers](#lesson-1--attaching-the-event-handlers)
18+
- [Lesson 2 – adding a counter](#lesson-2--adding-a-counter)
19+
- [Lesson 3 – improving the counter](#lesson-3--improving-the-counter)
20+
- [Lesson 4 – removing the buttons](#lesson-4--removing-the-buttons)
21+
- [Lesson 5 – reusability / marker class](#lesson-5--reusability--marker-class)
22+
- [Lesson 6 – reusability / only once](#lesson-6--reusability--only-once)
23+
- [Lesson 7 – making a jQuery plugin](#lesson-7--making-a-jquery-plugin)
3024

3125
## Preflight
3226

@@ -103,7 +97,11 @@ Unfortunately `let` is not supported in IE so far. To read more about the differ
10397

10498
If you need to support IE, it is probably safe to replace `let` with `var`. <small>And cope with the unexpected 😈</small>
10599

106-
## Lesson 1 – attaching the event handlers
100+
## Chapter one – basics
101+
102+
In this chapter we well learn the basics of jQuery selectors and event handlers.
103+
104+
### Lesson 1 – attaching the event handlers
107105

108106
Comes in handy
109107
- [Preflight / functions and arrow functions](#functions-and-arrow-functions)
@@ -122,14 +120,14 @@ The solution is possible without doing that.
122120
An explanation is attached to each solution.
123121
In this tutorial the solutions are ranked. Although all solutions will work, the first solution is the "worst" and the last solution is the "best". This has been done to provide the approach to the solution. Further lessons will base on the third solution.
124122

125-
### Get to the code
123+
#### Get to the code
126124

127125
- [Task – attaching the event handlers](https://codepen.io/mulithemuli/pen/JjPREzX)
128126
- [Solution #1](https://codepen.io/mulithemuli/pen/yLBaMem)
129127
- [Solution #2](https://codepen.io/mulithemuli/pen/pozEPGd)
130128
- [Solution #3](https://codepen.io/mulithemuli/pen/WNeGOxX)
131129

132-
## Lesson 2 – adding a counter
130+
### Lesson 2 – adding a counter
133131

134132
Print the number of times the button has been clicked to the bottom of the page in a specified container.
135133

@@ -139,12 +137,12 @@ Covered in this lesson
139137

140138
The area where the number of times clicked is defined. Local variable storage in the script has been reduced to a minimum.
141139

142-
### Get to the code
140+
#### Get to the code
143141

144142
- [Task – adding the counter](https://codepen.io/mulithemuli/pen/WNeGOaK)
145143
- [Solution](https://codepen.io/mulithemuli/pen/bGbwROK)
146144

147-
## Lesson 3 – improving the counter
145+
### Lesson 3 – improving the counter
148146

149147
Only updating the number of counts when the text actually has changed.
150148

@@ -153,12 +151,12 @@ Covered in this lesson
153151

154152
The change will be determined as previously but we need to check if the text has been changed.
155153

156-
### Get to the code
154+
#### Get to the code
157155

158156
- [Task – improving the counter](https://codepen.io/mulithemuli/pen/vYBXZMZ)
159157
- [Solution](https://codepen.io/mulithemuli/pen/VwZKWOp)
160158

161-
## Lesson 4 – removing the buttons
159+
### Lesson 4 – removing the buttons
162160

163161
The buttons are useful but not necessarily relevant to every user. We would like to hide (but not remove) the buttons and delegate the change of an input to the click of the button.
164162

@@ -168,12 +166,12 @@ Covered in this lesson
168166

169167
When JavaScript is active we would like to remove the button from the view but trigger its click action when the input has been changed.
170168

171-
### Get to the code
169+
#### Get to the code
172170

173171
- [Task – removing the buttons](https://codepen.io/mulithemuli/pen/VwZKWOp) (same as the solution from lesson 3)
174172
- [Solution](https://codepen.io/mulithemuli/pen/XWrjayp)
175173

176-
## Lesson 5 – reusability / marker class
174+
### Lesson 5 – reusability / marker class
177175

178176
Comes in handy
179177
- [Preflight / functions and arrow functions](#functions-and-arrow-functions)
@@ -185,31 +183,31 @@ Covered in this lesson
185183
- event delegation
186184
- jQuery [`.each()`](https://api.jquery.com/each/) function
187185

188-
### Get to the code
186+
#### Get to the code
189187

190188
- Task – reusability / marker class
191189
- Solution
192190

193-
## Lesson 6 – reusability / only once
191+
### Lesson 6 – reusability / only once
194192

195193
We can now select specific sections of the page to be handled as we like. But what if the DOM gets updated by an event like an AJAX call? The new DOM should get the same event handling as the other parts but the existing parts should not get the same events attached twice.
196194

197195
Covered in this lesson
198196
- remember marker classes
199197

200-
### Get to the code
198+
#### Get to the code
201199

202200
- Task – reusability / only once
203201
- Solution
204202

205-
## Lesson 7 – making a jQuery plugin
203+
### Lesson 7 – making a jQuery plugin
206204

207205
It is a solution which can be used by more than just us? To make it more convenient for the users we would like to create a jQuery plugin which does all this covered before.
208206

209207
Covered in this lesson
210208
- basic jQuery Plugin creation
211209

212-
### Get to the code
210+
#### Get to the code
213211

214212
- Task – making a jQuery plugin
215213
- Solution

0 commit comments

Comments
 (0)