You can only do so many compiler-y things in a dynamically typed language like Javascript. And even less of it within the context of a single file, unless you implement a bundler (web jargon equivalent of linker). Otherwise by the time the run-of-the-mill bundler is done connecting parts of your component tree into a single file, so much of the high-level information of the component is lost that you can't really do much analysis on it.
At least that were the reasons I saw when I was thinking about the same. If anyone has ideas around it, please get in touch.
At least that were the reasons I saw when I was thinking about the same. If anyone has ideas around it, please get in touch.