diff --git a/frontend/src/component/onboarding/sdkSnippets.ts b/frontend/src/component/onboarding/sdkSnippets.ts index d56c172cdb..4002023c6d 100644 --- a/frontend/src/component/onboarding/sdkSnippets.ts +++ b/frontend/src/component/onboarding/sdkSnippets.ts @@ -40,6 +40,8 @@ const unleash = initialize({ `, Go: `import ( "github.com/Unleash/unleash-client-go/v3" + "net/http" + "time" ) func init() { @@ -48,6 +50,7 @@ func init() { unleash.WithAppName("unleash-onboarding-golang"), unleash.WithUrl(""), unleash.WithCustomHeaders(http.Header{"Authorization": {""}}), + unleash.WithMetricsInterval(5*time.Second), ) }`, Ruby: `Unleash.configure do |config| @@ -192,7 +195,13 @@ export const checkFlagCodeSnippets: Record = { console.log('Is enabled', unleash.isEnabled('')); }, 1000); `, - Go: ``, + Go: `func main() { + for { + unleash.IsEnabled("") + time.Sleep(time.Second) + } +}, 1000); +`, Ruby: ``, PHP: ``, Rust: ``,