greenkeeper[bot] on core-js-3.5.0
chore(package): update core-js … (compare)
greenkeeper[bot] on can-observable-mixin-1.0.7
fix(package): update can-observ… (compare)
cherifGsoul on update-infrastructure-page
cherifGsoul on master
Update infrastructure page with… (compare)
cherifGsoul on update-infrastructure-page
Fix typos (compare)
cherifGsoul on document-inserted-removed-can6
Add inserted/removed events to … (compare)
greenkeeper[bot] on can-view-live-5.0.1
fix(package): update can-view-l… (compare)
let a = can.DefineMap.extend('a', {
init(){
console.log(arguments);
},
val: {
set(val){
console.log('hey there', val);
return val;
}
}
})
let b = new a();
b.val = 'Hello';
console.log(b.val)
can-map
and can-map-define
are legacy modules
canMap.extend(
/ @prototype */
{
define: {
/
* @property {office/models/session} office/components/navigation.loginSession loginSession
* @parent office/components/navigation.properties
*
* A placeholder session with a nested [office/models/user user] property that
* is used for two-way binding the login form's username and password.
*/
loginSession: {
value: function(){
return new Session({user: new User()});
}
}
/**
* @property {office/app} office/components/navigation.app app
* @parent office/components/navigation.properties
*
* The [office/app] used to add or destroy the session.
*/
/**
* @property {Promise<office/models/session>} office/components/navigation.sessionPromise sessionPromise
* @parent office/components/navigation.properties
*
* The promise that resolves when the user is logged in.
*/
},
/**
* @function createSession
*
* Creates the session on the server and when successful updates [office/components/navigation.app]
* with the session. Sets [office/components/navigation.sessionPromise].
* @param {Event} [ev] Optional DOM event that will be prevented if passed.
*/
createSession: function(ev){
if(ev) {
ev.preventDefault();
}
var self = this;
var sessionPromise = this.attr("loginSession").save().then(function(session){
self.attr("loginSession", new Session({user: new User()}));
self.attr("app").attr("session", session);
});
this.attr("sessionPromise", sessionPromise);
},
```