docs: update xposed-using

This commit is contained in:
2023-10-05 02:15:25 +08:00
parent b38d2b63ea
commit 545f7f92ab
2 changed files with 64 additions and 0 deletions

View File

@@ -66,6 +66,32 @@ If you want to use the module package name to be automatically generated, you ne
:::
::: danger
In Android Gradle Plugin **8+** versions, you need to manually enable **buildConfig** in the project's **build.gradle** or **build.gradle.kts**.
> Groovy DSL
```groovy
android {
buildFeatures {
buildConfig true
}
}
```
> Kotlin DSL
```kt
android {
buildFeatures {
buildConfig = true
}
}
```
:::
Example namespace `com.example.demo`, any one of the following definitions.
The following definitions are for reference only, usually **as long as your project can generate the `BuildConfig.java` file normally, no additional operations are required**.
@@ -101,6 +127,12 @@ If your module package name is automatically generated by unconventional means,
@InjectYukiHookWithXposed(modulePackageName = "com.example.demo")
```
:::danger
Please do not fill in **BuildConfig.APPLICATION_ID** in **modulePackageName**, this will get an empty string during compilation, depending on the behavior of the Android Gradle Plugin.
:::
As long as you customize the `modulePackageName` parameter, you will get a warning at compile time.
> The following example