Skip to content

Commit

Permalink
Merge branch 'dev' of https://github.com/jonobr1/two.js into dev
Browse files Browse the repository at this point in the history
  • Loading branch information
jonobr1 committed Feb 13, 2025
2 parents bae5e5a + e18e95e commit 86aa2aa
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/two.js
Original file line number Diff line number Diff line change
Expand Up @@ -250,7 +250,10 @@ export default class Two {
_.extend(this.renderer.domElement.style, {
display: 'block',
});
} else if (!_.isElement(params.domElement)) {
} else if (
typeof params.width === 'number' &&
typeof params.height === 'number'
) {
this.renderer.setSize(params.width, params.height, this.ratio);
this.width = params.width;
this.height = params.height;
Expand Down

0 comments on commit 86aa2aa

Please sign in to comment.