Add textview when click button



i want to add textview to page when i click button, please tell me about your solution


Should be easy,

import * { TextView } from "ui/text-view";
var textView = new TextView();


And incase you use JS version of nativescript

Just switch the import statement with

const TextView = require("ui/text-view").TextView;