SuperSimpleDev / javascript-course

682 stars 552 forks source link

Questioning the use of eval(), security issue? #43

Closed T0raT closed 1 year ago

T0raT commented 1 year ago

A quick search on mdn web docs tells me eval() is a huge security risk and is slower than the alternatives.

I understand for beginners' sake this might be an easier way to make a calculator. But if the aim is to go from beginner to pro, why isn't a warning given to the students regarding eval()'s security risk, or even discussed at all. I still see eval() being in the course solution up to lesson 10.

Why is this?

SuperSimpleDev commented 8 months ago

Thanks for this. Using eval() is to make it easier to create the calculator project. I'll add a note in the exercises that it's only for learning purposes and to avoid using it in real world projects.

T0raT commented 7 months ago

Thanks for this. Using eval() is to make it easier to create the calculator project. I'll add a note in the exercises that it's only for learning purposes and to avoid using it in real world projects.

Thanks for addressing the issue Simon!