[Date Prev][Date Next][Thread Prev][Thread Next]
- Subject: Re: Lua program structure
- From: Duke Normandin <dukeofpurl@...>
- Date: Fri, 27 May 2022 08:58:20 -0600
On Fri, 27 May 2022 16:04:56 +0200
Hugo Musso Gualandi <firstname.lastname@example.org> wrote:
> What I do on my projects: if the file is a standalone script I
> usually don't bother with creating a main function. I the module
> is intended to be used via require, I put the code inside an
> exported function. I don't want to have side effects when I
> call require("mymodule").
Thx! Very helpful.
** Bottom-posting, text-only is the netiquette way! **