logoalt Hacker News

maxpertyesterday at 10:03 PM7 repliesview on HN

I feel like Lua is absolutely underrated. I just wish one of the mainstream browsers actually puts their foot down and starts supporting Lua as scripting language.


Replies

inejgeyesterday at 10:40 PM

> I feel like Lua is absolutely underrated.

This sounds like an offhand Youtube comment, I'm afraid. Underrated how? Its principal strength, easy embedding with the ability to work as an extension language, is well known in the circles where it matters. The authors never gave an impression that they'd aim to make it a language to bury all other scripting languages, which I find refreshing in the winner-take-all culture of programming language discussion. Lua is modest and works well for what it is. No need to go all grandiose.

> I just wish one of the mainstream browsers actually puts their foot down and starts supporting Lua as scripting language.

I sincerely hope not, that would be a very counterproductive dilution of effort. Browser authors already have their plate full with all other web platform problems.

show 1 reply
esrauchyesterday at 11:08 PM

One of the super powers of Lua is that it doesn't need to be very stable: because you are always embedding an interpreter your code and interpreter have a matching version.

That's directly contrary to what would make it acceptable as a web spec, compared to e.g. wasm being powerful enough to be a compile target that can support wasm.

tormehyesterday at 10:20 PM

Ypu could probably run it in wasm. Of course, without access to the DOM it won't go any further than anything else on wasm. The whole thing is nuts if you ask me. So much lost potential.

show 2 replies
sellmesoapyesterday at 10:30 PM

I think that's doable. https://github.com/zacharie410/lua-browser-dom-demo

show 1 reply
irishcoffeeyesterday at 11:20 PM

Kind of feels like they would pick python before lua.

1313ed01yesterday at 10:12 PM

If they can lock it to some version to avoid breaking code every time there is a new Lua version. Or Lua stop making breaking changes.

klysmyesterday at 10:07 PM

Curious how this fits in with WASM