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

Improve the @pixi/runner developer experience #10243

Open
wants to merge 3 commits into
base: v7.x
Choose a base branch
from

Conversation

koteelok
Copy link
Contributor

Description of change

The current implementation of the `runner' package is not always usable with classes and can cause bugs due to overly complicated generics.

I removed default values of Runner generics, fixed improper use of unknown type and made types smaller to make errors more readable.

Also i found a bug(?) in BufferSystem caused by lack of strict checks that the object contains a callback function. I didn't add these checks myself so as not to change the APIs of this class too much, but this change may help us avoid similar problems in the future.
Let me know if it's OK to add them, I'll include them in this PR.

Instances problem

before

old1

now

new1

Explicit generics

before

old2

now

new2

Pre-Merge Checklist

  • Tests and/or benchmarks are included
  • Documentation is changed or added
  • Lint process passed (npm run lint)
  • Tests passed (npm run test)

Copy link

This pull request is automatically built and testable in CodeSandbox.

To see build info of the built libraries, click here or the icon next to each commit SHA.

Latest deployment of this branch, based on commit 688ab26:

Sandbox Source
pixi.js-sandbox Configuration

@koteelok koteelok changed the title Improve developer experience of @pixi/runner Improve the @pixi/runner developer experience Feb 27, 2024
@Zyie Zyie deleted the branch pixijs:v7.x March 5, 2024 17:16
@Zyie Zyie closed this Mar 5, 2024
@Zyie Zyie reopened this Mar 5, 2024
@Zyie Zyie changed the base branch from dev to v7.x March 5, 2024 18:04
@reececomo
Copy link

If you use any kind of code/property mangling for production bundles you might want to be passing this.myFunction.name instead of raw strings

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

Successfully merging this pull request may close these issues.

None yet

4 participants