Skip to content

Conversation

@ianpurvis
Copy link
Contributor

@ianpurvis ianpurvis commented Aug 1, 2020

I found that buble does not always place the prototype and constructor assignment at the end of the es6 class wrapper, which was breaking the transform for AudioListener (#19934 (comment))

This makes the string replacement more agnostic about where things are located. I also added some captures for some extra safety around the es6 class and parent class names.

Supports #11552

@mrdoob
Copy link
Owner

mrdoob commented Aug 2, 2020

Thanks for working on this 🙏

I've studied the problem and this is what's happening.

So far bubleCleanup was only able to handle buble's output of this:

class Dog extends Animal {

    constructor() {}

}

This PR adds support for buble's output of this:

class Dog extends Animal {

    constructor() {}

    bark() {}

    ...

}

@mrdoob mrdoob added this to the r120 milestone Aug 2, 2020
@mrdoob mrdoob merged commit ba2f9e4 into mrdoob:dev Aug 2, 2020
@mrdoob
Copy link
Owner

mrdoob commented Aug 2, 2020

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants