JSFiddle - React, Tailwind, and code Playground
JavaScript
debugger;
enyo.kind({
name : "testKind",
kind : "enyo.Application",
view : "ProgramsView",
});
enyo.kind({
name : "ProgramsView",
kind: "enyo.Control",
published: {
mymodel: {
kind: "enyo.Model",
id: "default id",
text: "default content"
},
test_id: "test id",
test_name: "Artem test name",
},
create: function(){
this.inherited(arguments);
var defaultModel = {
kind: "enyo.Model",
id: "my id",
text: "my content"
};
debugger;
this.set("mymodel", defaultModel);
},
rendered: function(){
this.inherited(arguments);
},
components: [
{name: "modelContentId", content: "no mo"},
{name: "modelContent", content: "no m"},
{name: "text_name", content: "no m",}
],
bindings: [
//{from: ".model.id", to: ".$.modelContentId.content"},
{from: ".mymodel.text", to: ".$.modelContent.content", transform: function(val) {
debugger;
return val;
}},
{from: ".test_name", to: ".$.text_name.content", transform: function(val) {
debugger;
return val;
}}
],
buttonTapped: function(inSender, inEvent) {
debugger;
app.$.detailsController.Index();
},
});
new testKind().renderInto(document.body);