Advertisement
Guest User

Untitled

a guest
Feb 20th, 2019
61
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.64 KB | None | 0 0
  1. class Test {
  2.  
  3. }
  4.  
  5. class Test2 extends Test {
  6.  
  7. }
  8.  
  9. function _inherits(subClass, superClass) {
  10. if (typeof superClass !== "function" && superClass !== null) {
  11. throw new TypeError("Super expression must either be null or a function, not " + typeof superClass);
  12. }
  13. subClass.prototype = Object.create(superClass && superClass.prototype, {
  14. constructor: {
  15. value: subClass,
  16. enumerable: false,
  17. writable: true,
  18. configurable: true
  19. }
  20. });
  21. if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass;
  22. }
  23.  
  24. if (superClass && !superClass.prototype)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement