Hello guys, I am trying to see if there is any doc...
# ask-questions
n
Hello guys, I am trying to see if there is any documentation on this for best practice for implementing on SPAs and using visual editor without any issues at all: https://linen.growthbook.io/t/13265064/it-s-not-clear-from-the-documentation-when-do-the-dom-mutati Any help will be much appreciated. Not sure if ambitious-parrot-39602 is about
s
That thread has good information. As it says there and in the docs, using the Visual Editor with React may not work optimally, and it's recommend to use feature flags. The main things to look out for, tho, is that you're passing in the right attributes to the SDK: ID and URL.
n
@strong-mouse-55694 Hi Ryan, so there is no way to make it work optimally even with passing right attributes?
s
There are a lot of variables, which make it hard to say for sure, especially in terms of how your app is rendering/re-rendering. My recommendation is to implement and see if it works: • You'll need to call
setURL
on route changes, so that GB knows the URL for targeting • Ensure the ID and any other required attrs are included If you do hit issues, share it with us and we can help debug. The other way to do this, which requires more infrastructure is to use the Edge SDK.
👍 1