Closed joeldenning closed 7 years ago
@joeldenning Thanks for this! Note, that upgrading to systemjs-hmr@next is going to be a breaking change anyway :) Since the whole state hydration mechanism is different.
Wait, I didn't see this console.logging code, but why not use a package like debug? That's way more flexible and used by a lot of other libraries. Although, more in Node.js than on the client side.
@peteruithoven Sure, all the same to me really, since this is the old version. Want to send a PR?
See https://github.com/alexisvincent/systemjs-hmr/pull/14, which is code that is waiting to be published in systemjs-hmr. Until that is published, this pull request should not be merged.
This simply exposes a new function
setDebugLogging
that allows the user to turn of logging things to the console. Note that when this project migrates to thenext.js
of systemjs-hmr, that this function will no longer be exported from systemjs-hmr. So potentially it would cause a breaking change for those who are using the function but then upgrade to systemjs-hmr@next.