-
Notifications
You must be signed in to change notification settings - Fork 40
feat(android): support bundled JS in debug builds #350
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
Changes from 1 commit
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -58,13 +58,20 @@ class VariantProcessor(private val variant: LibraryVariant) : BaseProject() { | |
| throw TaskNotFound("Can not find $preBuildTaskPath task") | ||
| } | ||
|
|
||
| if (capitalizedVariantName.contains("Release")) { | ||
| val bundledAssetsVariantName = Utils.getBundledAssetsVariantName(variant) | ||
| val capitalizedBundledAssetsVariantName = bundledAssetsVariantName.capitalized() | ||
|
|
||
| if (bundledAssetsVariantName != variant.name || capitalizedVariantName.contains("Release")) { | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Can you explain why we need to introduce
Collaborator
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Applied this simplification. The important part is not whether the current variant is So |
||
| val projectExt = project.extensions.getByType(Extension::class.java) | ||
| val appProject = project.rootProject.project(projectExt.appProjectName) | ||
| prepareTask.dependsOn("${appProject.path}:createBundle${capitalizedVariantName}JsAndAssets") | ||
| prepareTask.dependsOn( | ||
| "${appProject.path}:createBundle${capitalizedBundledAssetsVariantName}JsAndAssets", | ||
| ) | ||
|
|
||
| if (Utils.isExpoProject(project)) { | ||
| prepareTask.dependsOn("${appProject.path}:create${capitalizedVariantName}UpdatesResources") | ||
| prepareTask.dependsOn( | ||
| "${appProject.path}:create${capitalizedBundledAssetsVariantName}UpdatesResources", | ||
| ) | ||
| } | ||
| } | ||
|
|
||
|
|
||
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.
I am not sure whether we need this change. See the context below