Skip to content

Nt 3493 add dedicated react sdk hooks for common optimization state and actions#323

Open
Lotfi Anwar L Arif (Lotfi-Arif) wants to merge 2 commits into
NT-3492-improve-react-sdk-documentation-for-use-optimization-and-entry-interaction-setupfrom
NT-3493-add-dedicated-react-sdk-hooks-for-common-optimization-state-and-actions
Open

Nt 3493 add dedicated react sdk hooks for common optimization state and actions#323
Lotfi Anwar L Arif (Lotfi-Arif) wants to merge 2 commits into
NT-3492-improve-react-sdk-documentation-for-use-optimization-and-entry-interaction-setupfrom
NT-3493-add-dedicated-react-sdk-hooks-for-common-optimization-state-and-actions

Conversation

@Lotfi-Arif

Copy link
Copy Markdown
Contributor

No description provided.

…SDK method access

Added the `useOptimizationActions` hook to provide destructurable access to common SDK actions like `consent`, `identify`, `page`, and `track`. This change enhances the usability of the SDK in React components by promoting safer destructuring practices. Updated relevant documentation and examples to reflect this new hook, ensuring clarity for developers integrating the SDK.
Comment on lines +124 to +125
"index.cjs": 3400,
"index.mjs": 2500

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Because of the recent changes to React hooks, this was not sufficient, so I increased it slightly. I'm not sure if that is okay; otherwise, I can find another solution.

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.

1 participant