DEV Community

loading...

Discussion on: let, async, await as variable

Collapse
hardy613 profile image
Scott Hardy

The best practice is to pick either var or let, const. Mixing var, let and const together can lead to unexpected behavior.

var is function scoped, let, const are block scoped.