Skip to content
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

Make Module.transform configurable from evaluate #247

Merged
merged 2 commits into from
Oct 12, 2018

Conversation

giuseppeg
Copy link
Contributor

Replacement of #246

@callstack-bot
Copy link

callstack-bot commented Oct 12, 2018

Hey @giuseppeg, thank you for your pull request 🤗.
The coverage report for this branch can be viewed here.

@@ -58,7 +58,8 @@ const resolve = (path, t, requirements) => {
module.exports = function evaluate(
path /* : any */,
t /* : any */,
filename /* : string */
filename /* : string */,
transform /* : ?(text: string) => { code: string } */ = null
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the PR!

Just a nit, but can you extract the defaultTransform function to top of this function and use default parameter here? I think it'll be simpler.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

good idea thanks, done :)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

let me know if you prefer transform over transformModule

@satya164 satya164 merged commit fcec1bb into callstack:master Oct 12, 2018
@giuseppeg
Copy link
Contributor Author

awesome, thank you guys! :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants