Skip to content

renovate-reproductions/swc-jest

Repository files navigation

swc-jest

reproduce a swc jest bug

a swc decorator bug, moving the decorator below the tsdoc comment works as expected

fails

const printMemberName = (target: any, memberName: string) => {
    console.log(memberName);
  };

class TestClass {


  @printMemberName
  /**
   * some tsdoc comments
   * 
   * Some more comments
   * over
   * multiple
   * lines
   */
  async run(): Promise<boolean> {
    return await Promise.resolve(true);
  }
}

works

const printMemberName = (target: any, memberName: string) => {
    console.log(memberName);
  };

class TestClass {

  /**
   * some tsdoc comments
   * 
   * Some more comments
   * over
   * multiple
   * lines
   */
  @printMemberName
  async run(): Promise<boolean> {
    return await Promise.resolve(true);
  }
}

About

reproduce a swc jest bug

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published