Jump to content
Larry Ullman's Book Forums
Sign in to follow this  
AlexanderYu

Chapter 4, Two More Errata

Recommended Posts

Hi Larry,

 

Your book is great!I am reading it and practicing it.

 

Well, I think there is one small English language issue on Chapter 3, P81

 

"In a word, logical errors are bugs, commonly caused by the code doing exactly
what you told it to....."

 

I guess usually the phrase 'in a word' is just followed by a word, not a long sentence, right?

 

 

Alex

Share this post


Link to post
Share on other sites

Got it, thanks Larry.

 

As I am continuing reading Chapter 4, I found an additional '(' on P113:

 

"Thanks to the ability to chain object notation,
this could be reduced to one line:
if ( (document.getElementById(‘email’).value.length > 0) { ... "

 

This line of code has an extra opening parentheses before (document.getElementById...

Share this post


Link to post
Share on other sites

Also on P121:

 

-----

7. Add an event listener to the form:
function init() {
‘use strict’;
document.getElementById(‘calcForm’).onsubmit = formatNames;
} // End of init() function.

------

 

The code in Step 7 should actually refer to the element with an id value of theForm, which is what the corresponding downloadable code uses.

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
Sign in to follow this  

×
×
  • Create New...