-
-
Notifications
You must be signed in to change notification settings - Fork 560
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
yaml plugin: provide file id to transform function #615
Conversation
reason for this change: i need to apply different content transformations depending on which file the data came from without knowing the file, the transformer function has to rely on brittle heuristics to identify the file based on the content loaded from it (which can obviously change over time) non-breaking change since people don't have to use the extra transformer argument
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We still need a test case to make sure the correct path is being sent through. You can modify some of the existing tests to add that check.
@NotWoods Odd. If I run |
Ah, different directory separators on UNIX ( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks!
I was able to get it. |
@NotWoods Can you say when this will be published? |
@janosh we typically make weekly publish rounds for plugins. we have a lot moving parts this week so don't be surprised if this takes until early next week to be seen on NPM. (We're not quite ready for automated publishing) |
Rollup Plugin Name:
YAML
This PR contains:
Are tests included?
Breaking Changes?
Non-breaking change since people don't have to use the extra transformer argument.
Description
Reason for this change: I need to apply different content transformations depending on which file the data came from. Without knowing the file, the transformer function has to rely on brittle heuristics to identify the file based on its content (which can obviously change over time).
I think a new test case isn't needed for this but happy to provide one if someone thinks otherwise.