JS: define model