Reputation: 191
I'm trying to integrate these libraries into my Android project to make a navigation controller. When I add in these two lines to my build.gradle -
implementation 'android.arch.navigation:navigation-fragment:1.0.0-alpha01'
implementation 'android.arch.navigation:navigation-ui:1.0.0-alpha01'
It syncs ok, but in build I get this error:
ERROR: In NavArgument, unable to find attribute type.
I was able to build Google's sample project that uses the relevant libraries without problems.
My project has:
I've already tried upgrading all these versions^, doing a clean build, restarting Android Studio, etc.
I also get some Java compiler errors.
Any thoughts on why this might happen?
Upvotes: 1
Views: 401
Reputation: 36
You need to add the navigation value in your project :
and after that, if you have an error
invalid resource directory name: ..../res/merged/debug navigation
you need to remove android.enableAapt2=false
from your gradle.properties
Upvotes: 2