I’m trying to add a jar into a java library module...
# gradle
v
I’m trying to add a jar into a java library module, then pull that module into my app level build.gradle file as a dependency. Gradle syncs work. The issue is when I run gradlew assembleDebug, I keep getting the error
Copy code
Unresolved reference: creditcall
Execution failed for task ':app:compileDebugKotlin'
Library module: build.gradle
Copy code
apply plugin: 'java-library'
dependencies {
    implementation files("libs/MyCurrencyJar.jar")
}
App module: build.gradle
Copy code
...
dependencies {
   ...
    implementation project(':myLibrary')
}
Can I add a jar to a library module this way?
s
You should use
api
instead of
implementation
with that jar if you want consumers of the library to see it
v
ah thanks 🙏