Loading...
Loading...
Compare original and translation side by side
npm install -g nativescript
ns create my-appnpm install -g nativescript
ns create my-app
```typescript
// Accessing Native APIs directly (Android)
const time = new android.text.format.Time();
time.setToNow();
console.log(time.format("%d.%m.%Y"));
```typescript
// Accessing Native APIs directly (Android)
const time = new android.text.format.Time();
time.setToNow();
console.log(time.format("%d.%m.%Y"));new android.widget.Button(context)UILabel.alloc().init()new android.widget.Button(context)UILabel.alloc().init()StackLayoutGridLayoutFlexboxLayoutStackLayoutGridLayoutFlexboxLayoutWebpackWebpack| Error | Cause | Solution |
|---|---|---|
| Passing wrong type to native interaction. | Check native docs and cast types if needed. |
| Large images or memory leaks. | Use |
| Native dependency issues. | |
| 错误类型 | 原因 | 解决方案 |
|---|---|---|
| 向原生交互传递了错误的类型。 | 查看原生文档,必要时转换类型。 |
| 大图片或内存泄漏。 | 使用 |
| 原生依赖问题。 | 执行 |