{"_id":"@benfurkankilic/expo-yandex-mobile-ads","name":"@benfurkankilic/expo-yandex-mobile-ads","dist-tags":{"latest":"1.0.0"},"versions":{"1.0.0":{"name":"@benfurkankilic/expo-yandex-mobile-ads","version":"1.0.0","description":"Expo config plugin for Yandex Mobile Ads SDK 8 — auto-configures Info.plist, AndroidManifest, and SKAdNetwork IDs for React Native + Expo apps.","main":"app.plugin.js","scripts":{"build":"tsc -p plugin","clean":"rm -rf plugin/build","lint":"eslint plugin/src --ext .ts,.tsx","test":"jest","prepare":"npm run clean && npm run build","prepublishOnly":"npm run lint && npm run build"},"keywords":["expo","expo-config-plugin","react-native","yandex","yandex-ads","yandex-mobile-ads","monetization","ads","skadnetwork"],"repository":{"type":"git","url":"git+https://github.com/benfurkankilic/expo-yandex-mobile-ads.git"},"bugs":{"url":"https://github.com/benfurkankilic/expo-yandex-mobile-ads/issues"},"homepage":"https://github.com/benfurkankilic/expo-yandex-mobile-ads#readme","author":{"name":"Furkan Kilic","email":"hi@furkankilic.dev","url":"https://github.com/benfurkankilic"},"license":"MIT","publishConfig":{"access":"public"},"peerDependencies":{"expo":">=52","yandex-mobile-ads":">=8"},"devDependencies":{"@expo/config-plugins":"^11.0.0","@types/node":"^22.0.0","expo":"^55.0.18","expo-module-scripts":"^55.0.2","typescript":"^5.5.0"},"_id":"@benfurkankilic/expo-yandex-mobile-ads@1.0.0","gitHead":"7d525a8a3b4e92facee3885a3443b3adf4ef7471","_nodeVersion":"22.21.1","_npmVersion":"10.9.4","dist":{"integrity":"sha512-tVNIA0TGY3FzqrXz2Z9ANCAOROKhCx513jyjlSiXAICfeDjRM1WdksYr1IpKONWCGeFUjlPR6lr70b4j+a4onQ==","shasum":"73b43af6e57277c490809bf94ba8a1e67c2d5a73","tarball":"https://registry.npmjs.org/@benfurkankilic/expo-yandex-mobile-ads/-/expo-yandex-mobile-ads-1.0.0.tgz","fileCount":15,"unpackedSize":34787,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEUCIQCGO+dWve27rZb2WdFJwBJnRepaYHcVHRr1nnH+n2S8IAIgPqoQSwsRP5Tthkso24IIqYroJZ9hm1of6Tkb7cJelAY="}]},"_npmUser":{"name":"benfurkankilic","email":"hi@furkankilic.dev"},"directories":{},"maintainers":[{"name":"benfurkankilic","email":"hi@furkankilic.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/expo-yandex-mobile-ads_1.0.0_1777872472671_0.276749781456052"},"_hasShrinkwrap":false}},"time":{"created":"2026-05-04T05:27:52.572Z","1.0.0":"2026-05-04T05:27:52.834Z","modified":"2026-05-04T05:27:53.042Z"},"maintainers":[{"name":"benfurkankilic","email":"hi@furkankilic.dev"}],"description":"Expo config plugin for Yandex Mobile Ads SDK 8 — auto-configures Info.plist, AndroidManifest, and SKAdNetwork IDs for React Native + Expo apps.","homepage":"https://github.com/benfurkankilic/expo-yandex-mobile-ads#readme","keywords":["expo","expo-config-plugin","react-native","yandex","yandex-ads","yandex-mobile-ads","monetization","ads","skadnetwork"],"repository":{"type":"git","url":"git+https://github.com/benfurkankilic/expo-yandex-mobile-ads.git"},"author":{"name":"Furkan Kilic","email":"hi@furkankilic.dev","url":"https://github.com/benfurkankilic"},"bugs":{"url":"https://github.com/benfurkankilic/expo-yandex-mobile-ads/issues"},"license":"MIT","readme":"# @benfurkankilic/expo-yandex-mobile-ads\n\n> Expo config plugin for **Yandex Mobile Ads SDK 8** — auto-configures `Info.plist`, `AndroidManifest.xml`, and the full SKAdNetwork list so you can integrate Yandex ads in an Expo app in **under 2 minutes**.\n\n[![npm](https://img.shields.io/npm/v/@benfurkankilic/expo-yandex-mobile-ads.svg)](https://www.npmjs.com/package/@benfurkankilic/expo-yandex-mobile-ads)\n[![license](https://img.shields.io/npm/l/@benfurkankilic/expo-yandex-mobile-ads.svg)](./LICENSE)\n[![Expo](https://img.shields.io/badge/Expo-SDK%2052%2B-000020.svg)](https://expo.dev)\n[![Yandex SDK](https://img.shields.io/badge/Yandex%20Mobile%20Ads-SDK%208-FFCC00.svg)](https://www.npmjs.com/package/yandex-mobile-ads)\n\n---\n\n## Demo\n\nhttps://github.com/user-attachments/assets/d9a9960e-52f1-4baa-9c13-b5c6fe6903f1\n\n## Why this exists\n\nYandex Mobile Ads SDK 8 ships an [official React Native plugin](https://www.npmjs.com/package/yandex-mobile-ads) — but if you're on **Expo** (Managed or Bare), integrating it is painful:\n\n- iOS `Info.plist` needs **222 `SKAdNetworkIdentifier` entries** for Yandex + every mediation partner (AppLovin, AdMob, IronSource, Unity, Vungle, Mintegral, myTarget, Start.io)\n- AdMob mediation requires a `GADApplicationIdentifier` key\n- Android needs a `com.google.android.gms.ads.APPLICATION_ID` `<meta-data>` entry\n- Forgetting any of these silently breaks attribution or crashes the app at init\n\nThis plugin handles all of it during `expo prebuild`. Drop it in `app.json` and you're done.\n\n## Install\n\n```sh\nnpx expo install yandex-mobile-ads @benfurkankilic/expo-yandex-mobile-ads\n```\n\n> Both packages are required: `yandex-mobile-ads` ships the runtime SDK; this package only handles native config.\n\n## Configure\n\nAdd the plugin to your `app.json` (or `app.config.js`):\n\n```jsonc\n{\n  \"expo\": {\n    \"plugins\": [\n      [\n        \"@benfurkankilic/expo-yandex-mobile-ads\",\n        {\n          // All options are optional. Omit to use defaults.\n          \"iosAppId\": \"ca-app-pub-XXXXXXXXXXXXXXXX~YYYYYYYYYY\",\n          \"androidAppId\": \"ca-app-pub-XXXXXXXXXXXXXXXX~YYYYYYYYYY\",\n          \"userTrackingUsageDescription\": \"Used to deliver relevant ads.\"\n        }\n      ]\n    ]\n  }\n}\n```\n\nThen regenerate native projects:\n\n```sh\nnpx expo prebuild --clean\n```\n\nThat's it. Your `ios/<bundle>/Info.plist` and `android/app/src/main/AndroidManifest.xml` are now configured for Yandex Mobile Ads SDK 8.\n\n## Plugin options\n\nAll optional.\n\n| Option | Type | What it does |\n|---|---|---|\n| `iosAppId` | `string` | Your AdMob app ID — written to Info.plist as `GADApplicationIdentifier`. **Required if** you use AdMob mediation. Format: `ca-app-pub-XXXXXXXXXXXXXXXX~YYYYYYYYYY` |\n| `androidAppId` | `string` | Your AdMob app ID for Android — written to AndroidManifest.xml as `com.google.android.gms.ads.APPLICATION_ID` `<meta-data>`. Same format as `iosAppId`. |\n| `userTrackingUsageDescription` | `string` | Set the iOS App Tracking Transparency prompt text. Required if you want to request IDFA for mediation networks. Apple rejects vague phrasing — be specific. |\n| `extraSkAdNetworkItems` | `string[]` | Append additional SKAdNetwork IDs to the bundled list (for partners not yet covered). |\n| `skAdNetworkItems` | `string[]` | Replace the bundled SKAdNetwork list entirely. Advanced users only. |\n\nThe plugin **always** injects all 222 SKAdNetwork IDs from the official `yandex-mobile-ads@8` README — Yandex + every mediation partner adapter. App Store has no penalty for extras, and missing IDs silently break revenue.\n\n## Quick start (with code)\n\nAfter installation, use the [Yandex Mobile Ads SDK 8 API](https://www.npmjs.com/package/yandex-mobile-ads) in your screens. The full demo lives in [`example/App.tsx`](./example/App.tsx) — copy patterns from there. Highlights:\n\n```tsx\nimport { MobileAds, BannerView, BannerAdSize } from 'yandex-mobile-ads';\nimport { useEffect, useState } from 'react';\nimport { Dimensions } from 'react-native';\n\nexport default function App() {\n  // Initialize once\n  useEffect(() => { MobileAds.initialize(); }, []);\n  return <Banner />;\n}\n\nfunction Banner() {\n  const [size, setSize] = useState<BannerAdSize | null>(null);\n  useEffect(() => {\n    BannerAdSize.inlineSize(Dimensions.get('window').width, 250).then(setSize);\n  }, []);\n\n  if (!size) return null;\n  return (\n    <BannerView\n      size={size}\n      adRequest={{ adUnitId: 'demo-banner-yandex' }}\n      onAdLoaded={() => console.log('Loaded')}\n    />\n  );\n}\n```\n\n## Demo ad unit IDs\n\nYandex provides public demo IDs that always return a fill — perfect for development:\n\n| Format | Demo ID |\n|---|---|\n| Banner | `demo-banner-yandex` |\n| Interstitial | `demo-interstitial-yandex` |\n| Rewarded | `demo-rewarded-yandex` |\n| App Open | `demo-appopenad-yandex` |\n\nReplace with your real IDs from [partner.yandex.com](https://partner.yandex.com) before shipping.\n\n## Compatibility\n\n| Tool | Version |\n|---|---|\n| Expo | SDK 52+ |\n| React Native | 0.74+ |\n| `yandex-mobile-ads` | ^8.0.0 |\n| iOS | 13.0+ |\n| Android | minSdk 21+ |\n\nWorks with Expo Managed (via prebuild / EAS Build) and Bare workflows.\n\n## Mediation\n\nYandex Mobile Ads SDK 8 supports mediation with:\n\n- AppLovin MAX\n- Google AdMob\n- Mintegral\n- IronSource\n- Unity Ads\n- Vungle\n- myTarget (VK Ads)\n- Start.io\n\nRequired SKAdNetwork IDs for **all** of these are pre-configured by this plugin. For AdMob specifically, also pass `iosAppId` / `androidAppId`. For other adapters, follow [Yandex's mediation guide](https://ads.yandex.com/helpcenter/en/dev/react-native/quick-start-mm) for any additional Maven repositories you need to add.\n\n## How it works (under the hood)\n\nThe plugin runs at `expo prebuild` time and applies two mods:\n\n1. **`withInfoPlist`** — merges 222 SKAN IDs into `SKAdNetworkItems` (deduplicated against your existing entries), writes `GADApplicationIdentifier` and `NSUserTrackingUsageDescription` if you provided them.\n2. **`withAndroidManifest`** — idempotently upserts the AdMob `<meta-data>` tag if you provided `androidAppId`. Skipped entirely if not.\n\nIt's wrapped in `createRunOncePlugin` so re-running prebuild never duplicates entries.\n\nSee [`CLAUDE.md`](./CLAUDE.md) for the full architecture write-up.\n\n## Contributing\n\nPRs welcome. Read [`CONTRIBUTING.md`](./CONTRIBUTING.md) for the development workflow + style guide, and [`CLAUDE.md`](./CLAUDE.md) for the architecture decisions (which are deliberate).\n\nAll PRs require explicit approval from [@benfurkankilic](https://github.com/benfurkankilic) before merge — branch protection is enforced on `main`.\n\n```bash\ngit clone https://github.com/benfurkankilic/expo-yandex-mobile-ads.git\ncd expo-yandex-mobile-ads\nnpm install                  # builds the plugin via prepare script\ncd example && npm install\nnpx expo prebuild --clean    # exercise the plugin end-to-end\n```\n\n## License\n\nMIT © [Furkan Kılıç](https://github.com/benfurkankilic)\n\nThis plugin is **not** an official Yandex product. It's a community config plugin built on top of the official [`yandex-mobile-ads`](https://www.npmjs.com/package/yandex-mobile-ads) package.\n","readmeFilename":"README.md","_rev":"1-e1c4bce08d6e66d22027607755fafc2d"}