BREAKING: expose getTransformOptions directly in configuration

Summary:
Instead of exposing a `getTransformOptionsModulePath` function in configurations, we can simply expose a `getTransformOptions` *function*. The necessity of exposing a path comes from the olden days, where we had a server listening on a socket, and a client, talking to that server.

Since that architectural gem no longer exists, we can use functions directly, rather than passing paths to modules around.

Reviewed By: cpojer

Differential Revision: D4233551

fbshipit-source-id: ec1acef8e6495a2f1fd0911a5613c144e8ffd7c3
This commit is contained in:
David Aurelio
2016-11-28 07:27:09 -08:00
committed by Facebook Github Bot
parent c197c49123
commit 8ad2ab3b5e
7 changed files with 16 additions and 19 deletions

View File

@@ -28,7 +28,7 @@ function dependencies(argv, config, args, packagerInstance) {
const packageOpts = {
projectRoots: config.getProjectRoots(),
blacklistRE: config.getBlacklistRE(),
getTransformOptionsModulePath: config.getTransformOptionsModulePath,
getTransformOptions: config.getTransformOptions,
transformModulePath: transformModulePath,
extraNodeModules: config.extraNodeModules,
verbose: config.verbose,