Hacktoberfest 2026:维护者为十月标记出来的 issue,仍然开放、适合新手。 浏览 Hacktoberfest issue

Updating definitions to arbitrary android sdk version

未关闭
#21 1 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

还没有人认领这个 Issue。

评估

难度
4/5
预计耗时
3-5 天
新手友好度
30/100
Issue 类型
缺陷
描述清晰度
需要澄清
活跃度
停滞

调研方向

从 tns-platform-declarations/android/android.d.ts 开始,将生成的 android23.d.ts 与原始的 android17.d.ts 进行比较,重点关注缺失的 native 命名空间以及 TypeScript 报告的重复标识符。针对列出的 SDK 版本重新运行生成过程,并确定生成的声明是否能够在没有这些错误的情况下编译。

由索引模型根据 Issue 内容生成。

描述

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?

主要语言
Java
星标
96
派生
25
PR 合并指标
30 天内没有已合并 PR

环境准备

  • 没有 Dockerfile 或 Docker Compose 文件
  • 没有 Pull Request 模板
  • 阅读贡献指南

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

NativeScript/android-dts-generator 的其他 Issue

查看 NativeScript/android-dts-generator 的全部 Issue

相似的 Issue

更多 Java Issue

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。