we have a lot of examples of this already; for example haveActiveTask in compile.js, haveMainClass in run.js, etc. I do agree it has been useful to have have these in the JS mostly because it's easier to find them when refactoring (and therefore avoid breaking them).