Skip to content

Commit

Permalink
chore: updated sample app to use usersession on web platform
Browse files Browse the repository at this point in the history
  • Loading branch information
Desu Sai Venkat committed Nov 22, 2023
1 parent 937c931 commit ffaef7d
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions packages/example/lib/home_screen.dart
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,8 @@ class HomeScreenState extends State<HomeScreen> {
dbEncryption: dbEncryption,
recordScreenViews: true,
collectDeviceId: false);
WebConfig wc =
WebConfig(autoSessionTracking: true, sessionTimeoutInMillis: 10000);
RudderConfigBuilder builder = RudderConfigBuilder();
builder
..withFactory(RudderIntegrationAppcenterFlutter())
Expand All @@ -58,6 +60,7 @@ class HomeScreenState extends State<HomeScreen> {
..withDataPlaneUrl(
dotenv.env['DATA_PLANE_URL'] ?? "https://hosted.rudderlabs.com")
..withMobileConfig(mc)
..withWebConfig(wc)
..withLogLevel(RudderLogger.VERBOSE)
..withDataResidencyServer(DataResidencyServer.US);
String writeKey = dotenv.env['WRITE_KEY'] ?? "INVALID_WRITE_KEY";
Expand Down

0 comments on commit ffaef7d

Please sign in to comment.