-
Copy/paste
applixir-release.aar
file into your project's libraries.Path:
projectfolder->app>libs
-
Add the library implementation into your Gradle:
- In the
build.gradle
(module:app) file, in thedependencies
block, paste the following line:implementation files('libs/applixir-release.aar')
- In the
-
In the activity where you want to show the ad, add the Applixir ad launcher:
- Inside the activity class, initialize the ads launcher:
private var adsLauncher = registerForActivityResult(ActivityResultContracts.StartActivityForResult()) { result -> val isRewarded = checkRewardedAd(result) }
Whenever you want to launch the Applixir ad:
adsLauncher.launch(startApplixir(this@MainActivity, url = "https://js.applixirads.com/Android-test-1.html"))
- Inside the activity class, initialize the ads launcher: