Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Updating definitions to arbitrary android sdk version #21

Open
b12f opened this issue Apr 25, 2017 · 1 comment
Open

Updating definitions to arbitrary android sdk version #21

b12f opened this issue Apr 25, 2017 · 1 comment

Comments

@b12f
Copy link

b12f commented Apr 25, 2017

I'm trying to update my tns-platform-declarations to use the latest android sdk.

I've generated the definitions for the respective sdks and replaced the include in tns-platform-declarations/android/android.d.ts to use the generated file (currently android23.d.ts).

Problem is I now get - among others, including a lot of duplicate identifiers - a million error TS2503: Cannot find namespace 'native'., which tells me not everything has been extracted. Where do I go from here? The sdk declaration files have wildly differing sizes:

-rw-rw-r-- 1 yule yule 13777754 Apr 25 13:17 android17.d.ts # Original file
-rw-rw-r-- 1 yule yule  4686196 Apr 25 14:20 android20.d.ts
-rw-rw-r-- 1 yule yule  5191200 Apr 25 14:20 android21.d.ts
-rw-rw-r-- 1 yule yule  5214515 Apr 25 14:20 android22.d.ts
-rw-rw-r-- 1 yule yule  5006948 Apr 25 14:20 android23.d.ts
-rw-rw-r-- 1 yule yule 17178798 Apr 25 14:19 android24.d.ts
-rw-rw-r-- 1 yule yule  5730638 Apr 25 13:17 android25.d.ts

Which tells me I'm probably doing something wrong.

Do I have to include anything else?

@b12f
Copy link
Author

b12f commented Apr 25, 2017

I've looked into generate.win.bat and created an equivalent for Linux (you'll find some extra needed jars there), copied the android.d.ts from output/android-24 into the respective tns-platform-declarations folder, getting a lot less errors, now its mainly these two:

Namespace 'android' has no exported member 'content'.
Namespace 'android' has no exported member 'view'.

but org.nativescript.widgets.d.ts throws another bunch.

Edit: the extra jars aren't on my system. No error was thrown however.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant