gns_flutter_plugin 0.0.1 copy "gns_flutter_plugin: ^0.0.1" to clipboard
gns_flutter_plugin: ^0.0.1 copied to clipboard

outdated

Geniee SDK for Flutter platform

example/lib/main.dart

import 'dart:async';

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

void main() {
  runApp(const MyApp());
}

class MyApp extends StatefulWidget {
  const MyApp({super.key});

  @override
  State<MyApp> createState() => _MyAppState();
}

class _MyAppState extends State<MyApp> {
  @override
  void initState() {
    super.initState();
    initPlatformState();
  }

  // Platform messages are asynchronous, so we initialize in an async method.
  Future<void> initPlatformState() async {}

  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      home: Scaffold(
        appBar: AppBar(
          title: const Text('Plugin example app'),
        ),
        body: Center(
            child: Column(
          children: [
            Card(
              child: SizedBox(
                width: 300,
                height: 250,
                child: GNBannerAdWidget(
                  zoneId: "1530754",
                  onReceiveAd: () {
                    print("LongUni onReceiveAd flutter");
                  },
                  onFailedToReceiveAd: () {
                    print("LongUni onFailedToReceiveAd flutter");
                  },
                ),
              ),
            ),
            Card(
              child: SizedBox(
                width: 300,
                height: 250,
                child: GNBannerAdWidget(
                  zoneId: "1292558",
                  onReceiveAd: () {
                    print("LongUni onReceiveAd flutter");
                  },
                  onFailedToReceiveAd: () {
                    print("LongUni onFailedToReceiveAd flutter");
                  },
                ),
              ),
            ),
          ],
        )),
      ),
    );
  }
}
0
likes
0
points
12
downloads

Publisher

unverified uploader

Weekly Downloads

Geniee SDK for Flutter platform

License

unknown (license)

Dependencies

flutter, plugin_platform_interface

More

Packages that depend on gns_flutter_plugin

Packages that implement gns_flutter_plugin