Platform-specific TypeScript declarations for NativeScript for accessing native objects
84
Pending
Does it follow best practices?
Impact
84%
1.23xAverage score across 10 eval scenarios
Pending
The risk profile of this skill
{
"context": "This criteria evaluates how well the engineer uses the tns-platform-declarations package to access and configure AndroidX Material Design components, specifically the CardView from the androidx.cardview.widget package. The focus is on proper type reference inclusion, native view instantiation, and property configuration using AndroidX APIs.",
"type": "weighted_checklist",
"checklist": [
{
"name": "Triple-slash reference",
"description": "Includes the appropriate triple-slash reference directive at the top of the file (e.g., /// <reference path=\"node_modules/tns-platform-declarations/android.d.ts\" />) to enable AndroidX type definitions",
"max_score": 10
},
{
"name": "CardView instantiation",
"description": "Correctly instantiates androidx.cardview.widget.CardView using the native Android constructor (e.g., new androidx.cardview.widget.CardView(context))",
"max_score": 25
},
{
"name": "Corner radius configuration",
"description": "Uses the CardView.setRadius() method to configure corner radius",
"max_score": 15
},
{
"name": "Elevation configuration",
"description": "Uses the CardView.setCardElevation() method to set the card's elevation",
"max_score": 15
},
{
"name": "Background color configuration",
"description": "Uses the CardView.setCardBackgroundColor() method to set the card's background color",
"max_score": 15
},
{
"name": "Child view management",
"description": "Uses the CardView.addView() method to add child views to the card container",
"max_score": 10
},
{
"name": "Context handling",
"description": "Properly obtains and uses an Android Context object (e.g., via android.app.Application.getContext() or similar) when instantiating native views",
"max_score": 10
}
]
}evals
scenario-1
scenario-2
scenario-3
scenario-4
scenario-5
scenario-6
scenario-7
scenario-8
scenario-9
scenario-10