JSH318910: Use filter in for in loops |
JSH318910: Use filter in for in loops |
This option requires all for in loops to filter object's items. The for in statement allows for looping through the names of all of the properties of an object including those inherited throught the prototype chain. This behavior can lead to unexpected items in your object so it is generally safer to always filter inherited properties out (JSHint option 'forin')
TypeName: | UseFilterInForInLoops |
CheckId: | JSH318910 |
Severity: | Warning |
Type: | JavaScriptFile |
comments powered by Disqus
Copyright © 2013 RENCORE AB. All Rights Reserved
Disclaimer: The views and opinions expressed in this documentation and in SPCAF are those of the creators and do not necessarily reflect the opinions and recommendations of Microsoft or any member of Microsoft. All trademarks, service marks, collective marks, copyrights, registered names, and marks used or cited by this documentation are the property of their respective owners. SharePoint Code Analysis Framework, Version 4.5.2.7855, see www.spcaf.com for more information |