Last change
on this file since bdd6491 was 6a3a178, checked in by Ema <ema_spirova@…>, 3 years ago |
initial commit
|
-
Property mode
set to
100644
|
File size:
674 bytes
|
Line | |
---|
1 | function _defineProperties(target, props) {
|
---|
2 | for (var i = 0; i < props.length; i++) {
|
---|
3 | var descriptor = props[i];
|
---|
4 | descriptor.enumerable = descriptor.enumerable || false;
|
---|
5 | descriptor.configurable = true;
|
---|
6 | if ("value" in descriptor) descriptor.writable = true;
|
---|
7 | Object.defineProperty(target, descriptor.key, descriptor);
|
---|
8 | }
|
---|
9 | }
|
---|
10 |
|
---|
11 | function _createClass(Constructor, protoProps, staticProps) {
|
---|
12 | if (protoProps) _defineProperties(Constructor.prototype, protoProps);
|
---|
13 | if (staticProps) _defineProperties(Constructor, staticProps);
|
---|
14 | return Constructor;
|
---|
15 | }
|
---|
16 |
|
---|
17 | module.exports = _createClass;
|
---|
18 | module.exports["default"] = module.exports, module.exports.__esModule = true; |
---|
Note:
See
TracBrowser
for help on using the repository browser.