Title: Ask Reuben 13 - No More Globals Post by: Reuben B. on April 29, 2020, 05:29:30 am Does your code make use of GLOBALS, and do you find maintaining that code can be troublesome? To increase code re-usability and readability, use modular concepts and define PUBLIC variables in one or more modules that are imported into other modules as required with the IMPORT FGL instruction. In short ...
Code
... can be replaced with ... Code
... and in this module, the GLOBALS keyword ... Code
... can become ... Code
You can split your monolithic globals file into one or more smaller modules as required, and only reference the appropriate modules. Read more at https://4js.com/ask-reuben/ig-13/ |