Closed alvarosabu closed 1 year ago
The cause for this problem is that useTres
is not provided to components below TresScene
. That is the case, because the context is lost when the scene is mounted here. It works in cientos, because cientos does not use the symbol but the string 'useTres'
. I think we should make it use the symbol, for better typing and to avoid potential collisions.
Describe the bug When use
useTres
composable inside a sub-component to obtain the state, this state never gets updated. Curiously it does get updated when accessed fromcientos
or any other packageReproduction Please provide a link using this template on Stackblitz
Steps Steps to reproduce the behavior:
context
is updated with the correct value of stateExpected behavior State using
useTres
should provide correct updated stateScreenshots If applicable, add screenshots to help explain your problem.
System Info Output of
npx envinfo --system --npmPackages '{vite,@tresjs/*, three, vue}' --binaries --browsers
Additional context Add any other context about the problem here.