v1.1.0
This release adds the ability to specify a timeout for loading flags on the server. Flags usually resolve within ~75ms, but in case something goes wrong the flag evaluation requests can now be aborted at a user-configured timeout.
The configuration option can be set globally in configure()
for clientLoadingTimeout
, serverLoadingTimeout
and staticLoadingTimeout
each.
The global configuration can be overwritten per page by useFlags
and getFlags
by specifying the loadingTimeout
option.
Adds
config.clientLoadingTimeout
: The timeout used byuseFlags
on the clientconfig.serverLoadingTimeout
: The timeout used bygetFlags
inside ofgetServerSideProps
(for server-side rendering)config.staticLoadingTimeout
: The timeout used bygetFlags
inside ofgetStaticProps
orgetStaticPaths
(for static site generation)
Deprecates
configure({ loadingTimeout })
. Useconfigure({ clientLoadingTimeout })
instead. It behaves the same, it was renamed only.
Full Changelog: v1.0.2...v1.1.0