2016-03-25 20:03:49 +00:00
|
|
|
'use strict'
|
2016-02-22 04:13:26 +00:00
|
|
|
|
2016-03-25 20:03:49 +00:00
|
|
|
let value = 'old'
|
2016-02-22 04:13:26 +00:00
|
|
|
|
|
|
|
class BaseClass {
|
2016-03-25 20:03:49 +00:00
|
|
|
method () {
|
|
|
|
return 'method'
|
2016-02-22 04:13:26 +00:00
|
|
|
}
|
|
|
|
|
2016-03-25 20:03:49 +00:00
|
|
|
get readonly () {
|
|
|
|
return 'readonly'
|
2016-02-22 04:13:26 +00:00
|
|
|
}
|
|
|
|
|
2016-03-25 20:03:49 +00:00
|
|
|
get value () {
|
|
|
|
return value
|
2016-02-22 04:13:26 +00:00
|
|
|
}
|
|
|
|
|
2016-03-25 20:03:49 +00:00
|
|
|
set value (val) {
|
|
|
|
value = val
|
2016-02-22 04:13:26 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
class DerivedClass extends BaseClass {
|
|
|
|
}
|
|
|
|
|
|
|
|
module.exports = {
|
2016-03-28 23:11:00 +00:00
|
|
|
base: new BaseClass(),
|
|
|
|
derived: new DerivedClass()
|
2016-02-22 04:13:26 +00:00
|
|
|
}
|