Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Typedefs for new Phaser.Time.Timeline don't show it extending eventEmitter #6673

Closed
ghclark2 opened this issue Nov 16, 2023 · 1 comment
Closed

Comments

@ghclark2
Copy link

ghclark2 commented Nov 16, 2023

Version

  • Phaser Version: 3.70
  • Operating system: Windows
  • Browser: Chrome

Description

Typedefs for new Phaser.Time.Timeline don't show it extending eventEmitter. Eslint will give the following error with the code below: Property 'on' does not exist on type 'Timeline'.

Eslint will also give an error if you try to create an empty timeline: 'An argument for 'config' was not provided'. Config argument should be optional.

Example Test Code

const timeline = this.scene.add.timeline()
timeline.on('complete', () => {doSomething})

Additional Information

Thanks!

@photonstorm
Copy link
Collaborator

Thank you for submitting this issue. We have fixed this and the fix has been pushed to the master branch. It will be part of the next release. If you get time to build and test it for yourself we would appreciate that.

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

No branches or pull requests

3 participants