workshopper / scope-chains-closures

Javascript Scope Chains And Closures Workshop
ISC License
202 stars 142 forks source link

A bit confused after 1. Scopes #12

Open akiraspeirs opened 9 years ago

akiraspeirs commented 9 years ago

Hi,

I found some parts of the 1. Scopes exercise a bit confusing. I finished the exercise thinking that let and const could only be used in block scopes, and not in lexical scopes. I now know this is wrong on more than one level.

Also I was thrown off by the footnote This workshop will concentrate only on Lexical Scoping. After reading the footnote I reached a section called "Block Scopes", and was wondering if there was a type of block scope that was a lexical scope.

This could all just be me, but I thought it was worth mentioning.

Thanks for the workshop :)

jesstelford commented 9 years ago

Excellent feedback - thanks for taking the time :)

There is certainly a need to clarify the terminology used, and to bring some more coherence to the points explained in each lesson. There is also an open ticket for clarifying the difference between function vs lexical scope, which goes in hand with the differences between block and function. See #8.

As you've progressed through the lessons, did you find the confusion was cleared up? Is there something from later lessons that could be moved earlier to help?

Keep the great feedback coming, and please feel free to make a Pull Request with any changes you feel appropriate :)

akiraspeirs commented 9 years ago

The workshop was great, I enjoyed it and I think it clarified the concepts for me.

Are the following points correct? If they are, I feel like they're bits worth highlighting for someone like me:

I just read through the other issue and it seems to cover things in much greater detail. I should have checked that out first! Please feel free to close this one.