I have been using JS policy a lot in case i need to satisfy a use case that can't be done via policies. I had restricted myself to using "var" when it comes to declaring or instantiating variables. Recently, I found that we can use ES6 coding standards in JS policy and I started using "let" and "const" key words and ran into the following problems:
Please help me to understand, what exactly is happening here? @Dino-at-Google