I'm trying to wrap this simple API: https://github.com/github-tools/github, just for study purpose. So, I created this external classes:
package index
import com.github.jesty.githubapi.Result
import com.github.jesty.githubapi.User
import kotlin.js.Promise
external class GitHub(user: User) {
fun getUser(): GHUser
}
external class GHUser {
fun listStarredRepos(): Promise<Result>
}
In a simple KotlinJS project everything is ok, but when I try to use in a project created with Create React Kotlin App I have the error below:
ReferenceError: GitHub is not defined