tapsellorg / TapsellPlusSDK-ReactNativePlugin

2 stars 2 forks source link

🚀 [Feature]: Add React Native component for Standard Banner #9

Open mahdi-malv opened 3 years ago

mahdi-malv commented 3 years ago

Problem

Standard Banner is a view that will be added to the view as a FrameLayout child.
The only APIs to handle the position is simply Bottom, Top, left or right. Here's the sample code in the sample project

TapsellPlus.showStandardBannerAd(this.state.responseId,
        TapsellPlusHorizontalGravity.BOTTOM,
        TapsellPlusVerticalGravity.CENTER,
        (data) => {
          this._showToast('Data available: ' + data);
        },
        (error) => {
          this._showToast(`Error loading banner: ${error}`);
        });

This does not allow advance positioning and restricts the developer to only couple of states.

Solution

Plugin should provide a Platform native view component, so that it can be used as a regular component.