版博士V2.0程序
Вы не можете выбрать более 25 тем Темы должны начинаться с буквы или цифры, могут содержать дефисы(-) и должны содержать не более 35 символов.
 
 
 
 

58 строки
810 B

  1. const code =
  2. `
  3. const $ = require('../index');
  4. const XXMonitor = require('../monitor');
  5. var a = 1;
  6. var b = 2;
  7. a = 3;
  8. function add() {
  9. return a + b;
  10. }
  11. const c = add();
  12. function height() {
  13. return $('#1').height();
  14. }
  15. const h = height();
  16. let xxMonitor = new XXMonitor({
  17. appId: '123',
  18. env: 'test',
  19. userId: '123',
  20. plugins: ['p1'],
  21. });
  22. xxMonitor.start();
  23. window.addEventListener('load', function () {
  24. console.log('loaded');
  25. });
  26. function parent(){
  27. function test(){
  28. let a = 1;
  29. }
  30. const obj = { name: 'test' };
  31. }
  32. parent().test();
  33. const s = 'this is string';
  34. const car = {
  35. color: 'red'
  36. };
  37. car.color = 'green';
  38. const arr = [];
  39. arr = [1,2];
  40. const af = () => {
  41. console.log('this is arrow function' );
  42. }
  43. export sth from '@path/sth'
  44. `;
  45. module.exports = code;