An unofficial, read-only Hacker News reader.

Lua for data representation (2025) (opens external site)

104 points by vinhnx 4 days ago | citrons.xyz | 61 comments on HN

View full thread · View on Hacker News

Comment thread (1)

  1. Oh, I definitely agree that the issues of version compatibility are a problem for wider adoption. I have written a few small Lua projects, and I always struggle to decide which versions to support.

    If it had a few changes and perhaps some optional additions (while keeping a "classic" or "standalone" version), it would probably be more popular.

    > Unlike C++ Lua posits itself as an easy data representation and configuration language but it doesn't have a built-in way to load one of the most popular serialization formats out there these day.

    But that's the thing: if you want to represent data or configure something, wouldn't you prefer to do it in Lua? Seems the history of the language was using Lua syntax for the data representation, which is a bit more convenient than JSON for a few schemas. JSON is useful for interoperability, but it's far from my favorite for making a configuration file. The next project I'm working on is a small Lua script that will let the user configure itself via Lua, because that's more convenient than a static config format.