Skip to content

fix: dispose and lazy setters - #201

Merged
abernier merged 1 commit into
masterfrom
abernier/autofocus-fix01
May 12, 2023
Merged

fix: dispose and lazy setters#201
abernier merged 1 commit into
masterfrom
abernier/autofocus-fix01

Conversation

@abernier

@abernierabernier commented May 12, 2023

Copy link
Copy Markdown
Member
  • not missing .dispose()ing object
  • lazy setter
  • move to effects/ folder

Comment threadsrc/index.tsx
@@ -1,3 +1,4 @@
export * from './effects/Autofocus'

Copy link
Copy Markdown
MemberAuthor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I moved Autofocus to the effects/ folder

Comment on lines +59 to +60
depthPickingPass.dispose()
copyPass.dispose()

Copy link
Copy Markdown
MemberAuthor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

not missing .dispose() this time

Comment on lines +46 to +47
const [depthPickingPass] = useState(() => new DepthPickingPass())
const [copyPass] = useState(() => new CopyPass())

Copy link
Copy Markdown
MemberAuthor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lazy setter

@v1rtl

Copy link
Copy Markdown
Member

can you create a CSB or StackBlitz to test if it's working?

@abernier

abernier commented May 12, 2023

Copy link
Copy Markdown
MemberAuthor

I'm actually taking the opportunity to setup Storybook for the repo (like we have in rt/drei), so we can test rt/pp components directly from source-code in this PR: #202

@abernier

Copy link
Copy Markdown
MemberAuthor

can you create a CSB or StackBlitz to test if it's working?

Yes, I've tested it on my csb https://codesandbox.io/s/dfw6w4, it is working as before :)

@abernier
abernier merged commit 5d69491 into masterMay 12, 2023
@abernier
abernier deleted the abernier/autofocus-fix01 branch May 12, 2023 14:37
@github-actions

Copy link
Copy Markdown

🎉 This PR is included in version 2.11.1 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants

@abernier@v1rtl@CodyJasonBennett