https://www.growthbook.io/ logo
#ask-questions
Title
# ask-questions
m

microscopic-article-81707

08/10/2023, 11:29 AM
Quick Question. How well does Growthbook support offline clients? Is there a clean fallback mechanism if we can't request the feature toggle state?
w

white-fireman-22476

08/10/2023, 12:18 PM
Yes we fallback to the latest value that has been cached. If none have been cached then it falls back to the fallback listed in your code.
For example:
Copy code
// String/Number/JSON Feature Flag with a fallback
var value = gb.getFeatureValue("button-color", "blue")
if they are offline and nothing has been cached then value would be "blue".
m

microscopic-article-81707

08/10/2023, 1:27 PM
Fantastic, thank you. Looks like exactly what we need
15 Views