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

Audit all usages of has and isIn methods to check if they can be made more addon friendly #7306

Open
ChiefArug opened this issue Jan 20, 2025 · 0 comments
Assignees
Labels
area: api Issue or PR is related to API

Comments

@ChiefArug
Copy link

There are 96 files with usages of the has method on fields in the AllBlocks class (found by searching the create github for /AllBlocks\.[A-Z_]+\.has\(/).
This is one of the most common cases of mixins that is easiest to fix on the create side. Most of these usage should be able to be replaced with instanceof checks for the specific block classes, this would go a long way to breaking every single create addon again making create addons need less mixins and in general be more easily compatible with Create. In some cases these may potentially be made block tags, although that is probably quite a rare case.

A similar thing should be done to AllItems and isIn. Relevant search: /AllItems\.[A-Z_]+\.isIn\(/, although in this case most of these should be tags rather than an instanceof check (like #7234).

@IThundxr IThundxr self-assigned this Jan 20, 2025
@IThundxr IThundxr added the area: api Issue or PR is related to API label Jan 20, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: api Issue or PR is related to API
Projects
None yet
Development

No branches or pull requests

2 participants