mirror of
https://github.com/swc-project/swc.git
synced 2024-12-21 04:32:01 +03:00
18 lines
550 B
JavaScript
18 lines
550 B
JavaScript
|
function _classCallCheck(instance, Constructor) {
|
||
|
if (!(instance instanceof Constructor)) {
|
||
|
throw new TypeError("Cannot call a class as a function");
|
||
|
}
|
||
|
}
|
||
|
export var Class1 = function Class1(param) {
|
||
|
"use strict";
|
||
|
var _name = param.name, name = _name === void 0 ? '' : _name;
|
||
|
_classCallCheck(this, Class1);
|
||
|
console.log(name);
|
||
|
};
|
||
|
export var Class2 = function Class2(param) {
|
||
|
"use strict";
|
||
|
var _name = param.name, name = _name === void 0 ? '' : _name;
|
||
|
_classCallCheck(this, Class2);
|
||
|
console.log(name);
|
||
|
};
|