开发者

GAS files: how to free global space from polution?

开发者 https://www.devze.com 2022-12-07 22:40 出处:网络
How do I clean up my global space without having to create +1000 lines .gs files Here follows two photos of some of my files/folders. Mind how low the scroll bar can slide (30+ GAS files) ↓

How do I clean up my global space without having to create +1000 lines .gs files

  • Here follows two photos of some of my files/folders. Mind how low the scroll bar can slide (30+ GAS files) ↓

GAS files: how to free global space from polution?

GAS files: how to free global space from polution?

  • In Apps Script, .gs files cannot be manually mixed like .js modules, which means I cannot import or export (right?), neither control what will be shown when you search for completions;
  • If I wrap it around an interface, I usually end up with +1000 lines of cod开发者_Python百科e, which made the whole project difficult to read;
function groupOfFunctions() {
    this.doThis = function() { /* hundreds of lines */ };
    this.doThat = function() { /* hundreds of lines */ };
    // ...
    this.subFunc_N = function() { /* hundreds of lines */ };
    return this; // <-- makes tired face after this
};
  • To avoid that, the project's been organized in a way all Functions rest on the global space;
  • New problem: eventually, my global space has gotten heavily poluted with tons of Functions;

GAS files: how to free global space from polution?

GAS files: how to free global space from polution?

  • The scenario is: I usually forget what Functions do, or even that they exist (so many times I coded something that was ready, but lost a
  • I've found no Youtube videos, questions in forums or anything like it anywhere on the internet that talks about how to deal with it, so the question is:

How do I clean up my global space without having to create +1000 lines .gs files

Articles, blogs, videos etc. are welcome.

0

精彩评论

暂无评论...
验证码 换一张
取 消