Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Native banner for iOS #47

Closed
appycamper opened this issue Jun 28, 2020 · 5 comments
Closed

Native banner for iOS #47

appycamper opened this issue Jun 28, 2020 · 5 comments

Comments

@appycamper
Copy link

I tried adding native banner for iOS but not receiving any ads. Is this currently supported? Using v0.6.2

FacebookNativeAd(
                placementId: AdProvider.nativeBannerId,
                adType: NativeAdType.NATIVE_BANNER_AD,
                bannerAdSize: NativeBannerAdSize.HEIGHT_50,
                height: AdProvider.bannerHeight,
                width: double.infinity,
                backgroundColor: TGColors.adGray,
                titleColor: TGColors.gray,
                descriptionColor: TGColors.gray,
                buttonTitleColor: Colors.white,
                buttonColor: TGColors.darkBlue,
                buttonBorderColor: TGColors.darkBlue,
                expandAnimationDuraion: 200,
                keepExpandedWhileLoading: false,
              ),
@SachinGanesh
Copy link
Contributor

Try with Test ID's

@appycamper
Copy link
Author

I've added my iPhone's Identifier for Advertising (IDFA) as explained here

How do you obtain the hashed id for testing for iOS devices? they only show up on Android so I have nothing to put in as testingId

FacebookAudienceNetwork.init(
  testingId: "what do you put here for iOS devices"
);

@SachinGanesh
Copy link
Contributor

Replace your PLACEMENT_ID with IMG_16_9_APP_INSTALL#PLACEMENT_ID. You should get test ads.

Follow the instructions in this link to test the ads: https://developers.facebook.com/docs/audience-network/guides/test/inserted-code/

@mhle
Copy link

mhle commented Jun 30, 2020

The issue is using

keepExpandedWhileLoading: false

does not work for iOS, as there will be a white area where the banner should show up.

After removing that line, the test banner will show up correctly.

Hope you can update the docs accordingly.

@appycamper
Copy link
Author

@mhle Thanks that works! @SachinGanesh are you aware the stylings for native banner on iOS does not work? For example

backgroundColor: Colors.green

does not work. It works on Android though.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants