It’s really hard for the creator of Javascript to make money off of javascript, and it’s unlikely he has any financial interest in the Mozilla corporation anymore since they’re a nonprofit and thus don’t have share holders. However, he directly profits off of Brave.
Everything is harmful though, that’s the problem of existence. Nicotine is a psychoactive drug that does have both positive and negative effects. Vaping is safer than almost every other delivery method, and it’s the safest recreational delivery method available. There’s more than enough education on why nicotine is bad, which is the most you can really do.
People still drink, despite the physical addiction risks, the massive health risks of even a single drink a week, and the fact drinking any amount puts you almost comically more at risk of physical injury than not drinking. The education is fully out there. People still do it.
Free will is a hell of a thing, and restricting it has never ended well for those that restrict it, regardless of reason.