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

Factory initialization directly with Renderer #1615

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

MGreek
Copy link

@MGreek MGreek commented Apr 2, 2024

I made some changes to Factory such that FactoryOptions can now accept an instance of Renderer.

This fixes #580.

@ronyeh
Copy link
Collaborator

ronyeh commented Apr 26, 2024

Minor comment: Can you fix the typo in the second commit message?

allow initilalization => allow initialization

Do you have a small-ish example of using this new API? Either a JSFiddle or a snippet of code from a website you're building would help.

Thanks!

The `renderer` field of `FactoryOptions` was changed to also be an
instance of `Renderer` via an union.

The other way of initializing a `Factory` remains unaffected.

A test-case had to be slightly modified since it didn't account for
the union I created.

This fixes 0xfe#580 since an instance of `Renderer` can be created with DOM
elements and `Factory` can now be created with an instance of
`Renderer`.
@MGreek
Copy link
Author

MGreek commented Apr 27, 2024

Fixed the typo. I'll also try to do an example next.

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.

Passing DOM element to Factory's renderer.elementId param
2 participants