Skip to content

Commit

Permalink
Support experimental transform profile for bundle command (react-nati…
Browse files Browse the repository at this point in the history
  • Loading branch information
janicduplessis authored Nov 18, 2020
1 parent 5c563f7 commit c817bd3
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
2 changes: 2 additions & 0 deletions packages/cli/src/commands/bundle/buildBundle.ts
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ interface RequestOptions {
dev: boolean;
minify: boolean;
platform: string | undefined;
unstable_transformProfile: string | undefined;
}

export interface AssetData {
Expand Down Expand Up @@ -83,6 +84,7 @@ async function buildBundle(
dev: args.dev,
minify: args.minify !== undefined ? args.minify : !args.dev,
platform: args.platform,
unstable_transformProfile: args.unstableTransformProfile,
};
const server = new Server(config);

Expand Down
6 changes: 6 additions & 0 deletions packages/cli/src/commands/bundle/bundleCommandLineArgs.ts
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ export interface CommandLineArgs {
sourcemapSourcesRoot?: string;
sourcemapUseAbsolutePath: boolean;
verbose: boolean;
unstableTransformProfile?: string;
}

export default [
Expand Down Expand Up @@ -95,6 +96,11 @@ export default [
description:
'Directory name where to store assets referenced in the bundle',
},
{
name: '--unstable-transform-profile [string]',
description:
'Experimental, transform JS for a specific JS engine. Currently supported: hermes, hermes-canary, default',
},
{
name: '--reset-cache',
description: 'Removes cached files',
Expand Down

0 comments on commit c817bd3

Please sign in to comment.