nn_counter_tracker 0.3.0 copy "nn_counter_tracker: ^0.3.0" to clipboard
nn_counter_tracker: ^0.3.0 copied to clipboard

Lightweight, highly customizable analytics-style tracking for Flutter widgets: views, impressions, taps, clicks and user interactions. Works like a mini analytics SDK while staying simple and develope [...]

example/lib/main.dart

import 'package:flutter/material.dart';
import 'package:nn_counter_tracker/nn_counter_tracker.dart';

import 'pages/product_feed_page.dart';

Future<void> main() async {
  WidgetsFlutterBinding.ensureInitialized();

  // Enable logs. Uses the default plugin-free in-memory storage, so this demo
  // runs on every platform (including Windows) with no extra setup.
  CounterTrackerService.instance.configure(enableLogs: true);
  await CounterTrackerService.instance.init();

  runApp(const ExampleApp());
}

/// Root widget of the example application.
class ExampleApp extends StatelessWidget {
  /// Creates the example app.
  const ExampleApp({super.key});

  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      title: 'nn_counter_tracker demo',
      debugShowCheckedModeBanner: false,
      theme: ThemeData(colorSchemeSeed: Colors.indigo, useMaterial3: true),
      home: const ProductFeedPage(),
    );
  }
}
4
likes
145
points
94
downloads

Documentation

API reference

Publisher

unverified uploader

Weekly Downloads

Lightweight, highly customizable analytics-style tracking for Flutter widgets: views, impressions, taps, clicks and user interactions. Works like a mini analytics SDK while staying simple and developer-friendly.

Repository (GitHub)
View/report issues

Topics

#analytics #tracking #counter #impressions #visibility

License

MIT (license)

Dependencies

flutter, visibility_detector

More

Packages that depend on nn_counter_tracker