Create a gist now

Instantly share code, notes, and snippets.

What would you like to do?
simple HelloWorld app
var MainActivity = (function (_super) {
__extends(MainActivity, _super);
function MainActivity() {
}
MainActivity.prototype.onCreate = function () {
_super.prototype.onCreate.call(this, null);
var layout = new android.widget.LinearLayout(this);
layout.setOrientation(1);
this.setContentView(layout);
var textView = new android.widget.TextView(this);
textView.setText("Hello world");
layout.addView(textView);
};
return MainActivity;
})(com.tns.NativeScriptActivity);
app.init({
getActivity: function(intent) {
return MainActivity;
}
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment