{"id":17650727,"url":"https://github.com/eaceto/react-native-youtube-player","last_synced_at":"2025-07-27T01:04:58.585Z","repository":{"id":57341652,"uuid":"100408055","full_name":"eaceto/react-native-youtube-player","owner":"eaceto","description":"A React Native module that allows you to play YouTube videos from React Native Apps.","archived":false,"fork":false,"pushed_at":"2018-10-24T23:19:43.000Z","size":91,"stargazers_count":5,"open_issues_count":6,"forks_count":1,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-07-20T05:17:14.893Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Objective-C","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/eaceto.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2017-08-15T18:42:29.000Z","updated_at":"2024-04-04T11:38:34.000Z","dependencies_parsed_at":"2022-09-15T16:42:07.180Z","dependency_job_id":null,"html_url":"https://github.com/eaceto/react-native-youtube-player","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/eaceto/react-native-youtube-player","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eaceto%2Freact-native-youtube-player","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eaceto%2Freact-native-youtube-player/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eaceto%2Freact-native-youtube-player/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eaceto%2Freact-native-youtube-player/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/eaceto","download_url":"https://codeload.github.com/eaceto/react-native-youtube-player/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eaceto%2Freact-native-youtube-player/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":267278631,"owners_count":24063252,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-07-26T02:00:08.937Z","response_time":62,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-10-23T11:39:20.106Z","updated_at":"2025-07-27T01:04:58.565Z","avatar_url":"https://github.com/eaceto.png","language":"Objective-C","funding_links":[],"categories":[],"sub_categories":[],"readme":"\n# React Native Youtube Player [![npm version](https://badge.fury.io/js/react-native-youtube-player.svg)](https://badge.fury.io/js/react-native-youtube-player) [![npm](https://img.shields.io/npm/dt/react-native-youtube-player.svg)](https://www.npmjs.org/package/react-native-youtube-player) ![MIT](https://img.shields.io/dub/l/vibe-d.svg) ![Platform - Android and iOS](https://img.shields.io/badge/platform-Android%20%7C%20iOS-yellow.svg)\n\nA React Native module that allows you to play YouTube videos from React Native Apps.\n\nYouTube example video of this lib working on iOS -\u003e https://www.youtube.com/watch?v=rGq_y5pF0xA\u0026feature=youtu.be\n\n## Table of contents\n- [Install](#install)\n- [Usage](#usage)\n- [Direct launch](#directly-launching-the-camera-or-image-library)\n- [Options](#options)\n- [Response object](#the-response-object)\n\n## Install\n\n### NOTE: THIS PACKAGE IS NOW BUILT FOR REACT NATIVE 0.40 OR GREATER! IF YOU NEED TO SUPPORT REACT NATIVE \u003c 0.40, YOU SHOULD INSTALL THIS PACKAGE `@0.24`\n\n`npm install react-native-youtube-player@latest --save`\n\n### Automatic Installation\n\n`react-native link`\n\nIMPORTANT NOTE: You'll still need to perform step 4 and 5 for iOS and steps 2, 3, and 5 for Android of the manual instructions below.\n\n### Manual Installation\n\n#### iOS\n\n1. In the XCode's \"Project navigator\", right click on your project's Libraries folder ➜ `Add Files to \u003c...\u003e`\n2. Go to `node_modules` ➜ `react-native-youtube-player` ➜ `ios` ➜ select `RNYoutubePlayer.xcodeproj`\n3. Add `RNYoutubePlayer.a` to `Build Phases -\u003e Link Binary With Libraries`\n4. For iOS verify your ATS configuration\n5. Drag and Drop \"YTPlayerView-iframe-player.html\" and \"YoutubePlayerViewController.xib\" to your main project (in Xcode). Copy those files. You can customize the XIB file in order to localize for example.\n6. Compile and have fun\n\n#### Android\n1. Add the following lines to `android/settings.gradle`:\n    ```gradle\n    include ':react-native-youtube-player'\n    project(':react-native-youtube-player').projectDir = new File(rootProject.projectDir, '../node_modules/react-native-youtube-player/android')\n    ```\n    \n2. Update the android build tools version to `2.2.+` in `android/build.gradle`:\n    ```gradle\n    buildscript {\n        ...\n        dependencies {\n            classpath 'com.android.tools.build:gradle:2.2.+' // \u003c- USE 2.2.+ version\n        }\n        ...\n    }\n    ...\n    ``` \n    \n3. Update the gradle version to `2.14.1` in `android/gradle/wrapper/gradle-wrapper.properties`:\n    ```\n    ...\n    distributionUrl=https\\://services.gradle.org/distributions/gradle-2.14.1-all.zip\n    ```\n    \n4. Add the compile line to the dependencies in `android/app/build.gradle`:\n    ```gradle\n    dependencies {\n        compile project(':react-native-youtube-player')\n    }\n    ```\n    \n5. Add the required permissions in `AndroidManifest.xml`:\n    ```xml\n    \u003cuses-permission android:name=\"android.permission.INTERNET\" /\u003e\n    ```\n    \n6. Add the import and link the package in `MainApplication.java`:\n    ```java\n    import ar.com.ezequielaceto.reactnative.library.youtubeplayer.YoutubePlayerPackage; // \u003c-- add this import\n\n    public class MainApplication extends Application implements ReactApplication {\n        @Override\n        protected List\u003cReactPackage\u003e getPackages() {\n            return Arrays.\u003cReactPackage\u003easList(\n                new MainReactPackage(),\n                new YoutubePlayerPackage()\n            );\n        }\n    }\n    ```\n\n```\nThis code allows to pass result of request permissions to native part.\n\n## Usage\n\n```javascript\nvar YoutubePlayer = require('react-native-youtube-player');\n\nvar options = {\n  title: 'An example project'\n};\n\nYoutubePlayer.playVideo(\"youtube-video-id\", options);\n```javascript\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Feaceto%2Freact-native-youtube-player","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Feaceto%2Freact-native-youtube-player","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Feaceto%2Freact-native-youtube-player/lists"}