-
-
Notifications
You must be signed in to change notification settings - Fork 108
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
fix(core): add new launch.json and fixed breakpoints not working #599
base: main
Are you sure you want to change the base?
fix(core): add new launch.json and fixed breakpoints not working #599
Conversation
✅ Deploy Preview for tresjs-docs ready!
To edit notification comments on pull requests, go to your Netlify site configuration. |
: useElementSize(computed(() => toValue(canvas).parentElement)) | ||
: useElementSize( | ||
computed( | ||
() => toValue(canvas).parentElement, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi @ThimoDEV why is this change needed?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi @alvarosabu There is an issue when the TresCanvas uses the parent element width and height.
The usElementSize composable from VueUse loses its reactivity I assume which causes the TresCanvas width and height to be 0.
This issue occurs when you hit a breakpoint and continue debugging after. When you use the useWindowSize
prop this doesn't happen.
This fixes that
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@ThimoDEV would be possible to have this change in a separate PR, is a little bit confusing to understand the scope of this one.
@alvarosabu Is there anything more you need/changed for this to be merged? So I can help get you there :) |
: useElementSize(computed(() => toValue(canvas).parentElement)) | ||
: useElementSize( | ||
computed( | ||
() => toValue(canvas).parentElement, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@ThimoDEV would be possible to have this change in a separate PR, is a little bit confusing to understand the scope of this one.
This PR adds a new launch.json so a maintainer of TresJS can use breakpoints during development.
How to use?
pnpm playground
Run and debug
windowI had this weird issue where the localhost url wasn't working. I set the port on all to 3000 which seems to make the dev server more stable. I don't know if this impacts releases in any way?