This repository was archived by the owner on May 30, 2025. It is now read-only.
v2.0.0
- adds support for Next.js Middleware
- you can now use
getEdgeFlags
to load your flags in middleware - see a demo of using flags in middleware at flags.happykit.dev/demo/middleware
- you can now use
BREAKING CHANGES
next
v12.0.2 is now the new minimalpeerDependency
(as this is the first version supporting middleware and settingmaxAge
correctly)- older Next.js versions should still if you are not using
getEdgeFlags
- older Next.js versions should still if you are not using
- we now recommend storing your config in
flags.config.js
as shown in the example and then importingflags.config
into_app
- note that
configure()
is now called from withinflags.config.ts
- note that
configure()
is no longer called in_app.tsx
- calling
configure()
fromflags.config.ts
prepares you for loading flags in_middleware
by importingflags.config
- note that