add the filename in the warning message#10
Open
Roilan wants to merge 2 commits intochromakode:masterfrom
Open
Conversation
Owner
|
Trying to understand the use case here -- do you want to know that this warning is coming from react-html-email, or the exact file the warning came from? I think changing the text to be like "Warning (react-html-email):" would be a good idea, but I'm a little hesitant to add the complexity of resolving the filename. I haven't seen other modules behave like this; for instance React will also output warnings without a mention of their origin file. I wonder if this is something you could implement more generally for your application purposes by monkeypatching |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
As I'm building out a email template system with this module, I've noticed that warning message doesn't specify where it comes from. At the moment, we assume everything is one giant component, which we shouldn't.
I'm currently digging through
module.parentbut if you have a better way / idea of finding the root source, please share!