The title is a duplicate but my question is different.
The same project works fine and is allowed to be built on
buildToolsVersion 23.0.3
I solved this issue:
added this code in android/build.gradle
android/build.gradle
```
subprojects { afterEvaluate {project -> if (project.hasProperty("android")) { android { compileSdkVersion 26 buildToolsVersion '26.0.0' } } } }