Closed mnquintana closed 7 years ago
Figure out how best to express the dependency between compile and determineDependentFiles (ie. determineDependentFiles must be called before compile)
The order methods are called during compilation are guaranteed by electron-compile, you don't have to worry about compile being called before determineDependentFiles
@paulcbetts Not in this second case:
Right now it's handled in CompilerHost, BUT it's possible for a compiler to require other compilers directly, like InlineHtml does, in which case we currently have to duplicate the logic
✨
⚠️ Work in progress ⚠️
Part of https://github.com/electron/electron-compile/issues/27
This PR implements
determineDependentFiles
for Less, which should giveelectron-compile
everything it needs to know to properly recompile a Less file's dependencies. ✨TODO
compile
anddetermineDependentFiles
(ie.determineDependentFiles
must be called beforecompile
)CompilerHost
, BUT it's possible for a compiler to require other compilers directly, likeInlineHtml
does, in which case we currently have to duplicate the logicCompilerBase
should calldetermineDependentFiles
in its basecompile
methods, and then we just call the superclass methods from the subclasses? I dunnocompilerContext
fromdetermineDependentFiles
and throwing them oncompile
, but I dunno how I feel about that 😕