{"_id":"@anivire/twitch-embed-ts","_rev":"4-4e5408d7705d00e423da48d9fc5a5593","name":"@anivire/twitch-embed-ts","dist-tags":{"latest":"0.0.3"},"versions":{"0.0.1":{"name":"@anivire/twitch-embed-ts","version":"0.0.1","keywords":["twitch-embed-api","twitch-player","twitch-embed"],"author":{"url":"https://github.com/anivire","name":"anivire"},"license":"MIT","_id":"@anivire/twitch-embed-ts@0.0.1","maintainers":[{"name":"anivire","email":"anivire.work@gmail.com"}],"homepage":"https://github.com/anivire/twitch-embed-ts#readme","bugs":{"url":"https://github.com/anivire/twitch-embed-ts/issues"},"dist":{"shasum":"0d0404c58b0dc732f95d13ef64ec0785499c4f8c","tarball":"https://registry.npmjs.org/@anivire/twitch-embed-ts/-/twitch-embed-ts-0.0.1.tgz","fileCount":8,"integrity":"sha512-P57VKbmrAVnb9z0HeAUwpAYSYyDePDp7AfYlN2C6AQU1L46IgsM4q6ajD8Xd9b65d8mN77Dnq6mzDSPRGTH4cg==","signatures":[{"sig":"MEUCIBhIXtPCWLsTtBXh4a7dPtpzoDhgeHbmkmdeOLNxPT1dAiEA3c4CchccwzUR+VKqh2yolmf6PEfMsuxKQyCIG1QNaFE=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":1399034},"main":"dist/index.js","types":"dist/index.d.ts","module":"dist/index.mjs","gitHead":"60fb6448e87544337fc011f5dc08062f59d796bc","scripts":{"lint":"tsc","build":"tsup ./src/index.ts --format cjs,esm --dts"},"_npmUser":{"name":"anivire","email":"anivire.work@gmail.com"},"repository":{"url":"git+https://github.com/anivire/twitch-embed-ts.git"},"_npmVersion":"10.2.3","description":"Twitch Embed API Typescript wrapper","directories":{},"_nodeVersion":"20.10.0","dependencies":{"tsup":"^8.0.2","@changesets/cli":"^2.27.1"},"_hasShrinkwrap":false,"devDependencies":{"typescript":"^5.3.3"},"_npmOperationalInternal":{"tmp":"tmp/twitch-embed-ts_0.0.1_1708181056147_0.952882080083479","host":"s3://npm-registry-packages"},"deprecated":"Package no longer supported. Contact Support at https://www.npmjs.com/support for more info."},"0.0.2":{"name":"@anivire/twitch-embed-ts","version":"0.0.2","keywords":["twitch-embed-api","twitch-player","twitch-embed"],"author":{"url":"https://github.com/anivire","name":"anivire"},"license":"MIT","_id":"@anivire/twitch-embed-ts@0.0.2","maintainers":[{"name":"anivire","email":"anivire.work@gmail.com"}],"homepage":"https://github.com/anivire/twitch-embed-ts#readme","bugs":{"url":"https://github.com/anivire/twitch-embed-ts/issues"},"dist":{"shasum":"4aeea1d864637bc77236fe2d8dc9fd3e1b31087f","tarball":"https://registry.npmjs.org/@anivire/twitch-embed-ts/-/twitch-embed-ts-0.0.2.tgz","fileCount":8,"integrity":"sha512-cUCfaJnpSb2e2Wbg2DBy8gS0KTh9DsvkvqX+TVXWX0xZNYHJvc4D7fBrBJ3EdzYptt+CfOsZ4rXMrvDyGcGqHg==","signatures":[{"sig":"MEUCIQCBG2M0jSmt/Us73X3yLW/LZL/aXKh6UmYrl2yhIzpzrwIgXReuC4OEoipJRb+FIPecYmy3Ib+qkS1S+52IN34s9kA=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":1398480},"main":"dist/index.js","types":"dist/index.d.ts","module":"dist/index.mjs","gitHead":"754974111e13fe0f27283b4ee7491e7a1eb79305","scripts":{"build":"tsup ./src/index.ts"},"_npmUser":{"name":"anivire","email":"anivire.work@gmail.com"},"repository":{"url":"git+https://github.com/anivire/twitch-embed-ts.git"},"_npmVersion":"10.2.3","description":"Twitch Embed API Typescript wrapper","directories":{},"_nodeVersion":"20.10.0","dependencies":{"tsup":"^8.0.2"},"_hasShrinkwrap":false,"devDependencies":{"typescript":"^5.3.3"},"_npmOperationalInternal":{"tmp":"tmp/twitch-embed-ts_0.0.2_1708182289923_0.13424618217539708","host":"s3://npm-registry-packages"},"deprecated":"Package no longer supported. Contact Support at https://www.npmjs.com/support for more info."},"0.0.3":{"name":"@anivire/twitch-embed-ts","version":"0.0.3","keywords":["twitch-embed-api","twitch-player","twitch-embed"],"author":{"url":"https://github.com/anivire","name":"anivire"},"license":"MIT","_id":"@anivire/twitch-embed-ts@0.0.3","maintainers":[{"name":"anivire","email":"anivire.work@gmail.com"}],"homepage":"https://twitch-embed-ts-docs.vercel.app/getting-started","bugs":{"url":"https://github.com/anivire/twitch-embed-ts/issues"},"dist":{"shasum":"9064cee129cb713f8dc069c2e39c61d7032feaa3","tarball":"https://registry.npmjs.org/@anivire/twitch-embed-ts/-/twitch-embed-ts-0.0.3.tgz","fileCount":8,"integrity":"sha512-Nx9F5WxEz6f/8nWqB4a6qcb3HqglrffevJGVc7IA9mrigUBzFSdLbZkUiJZj5UtKB2glrllC+h5cRm/k27jp8A==","signatures":[{"sig":"MEQCIB0cq3ngKtGZeoLcapvd8URnyX30B1IM7ZHOLlxPspEPAiBbtBcvaJvfIP9oh/BE03aaKXEQvfcyuRG07AngwkM1ig==","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":1396891},"main":"dist/index.js","types":"dist/index.d.ts","module":"dist/index.mjs","gitHead":"c99f5fcca3f5d3881819b22f429f3f83677408ec","scripts":{"build":"tsup ./src/index.ts"},"_npmUser":{"name":"anivire","email":"anivire.work@gmail.com"},"repository":{"url":"git+https://github.com/anivire/twitch-embed-ts.git"},"_npmVersion":"10.2.3","description":"Twitch Embed API Typescript wrapper","directories":{},"_nodeVersion":"20.10.0","dependencies":{"tsup":"^8.0.2"},"_hasShrinkwrap":false,"devDependencies":{"typescript":"^5.3.3"},"_npmOperationalInternal":{"tmp":"tmp/twitch-embed-ts_0.0.3_1708473741455_0.9846424412309613","host":"s3://npm-registry-packages"},"deprecated":"Package no longer supported. Contact Support at https://www.npmjs.com/support for more info."}},"time":{"created":"2024-02-17T14:44:16.046Z","modified":"2025-09-11T19:18:37.881Z","0.0.1":"2024-02-17T14:44:16.359Z","0.0.2":"2024-02-17T15:04:50.217Z","0.0.3":"2024-02-21T00:02:21.673Z"},"bugs":{"url":"https://github.com/anivire/twitch-embed-ts/issues"},"author":{"url":"https://github.com/anivire","name":"anivire"},"license":"MIT","homepage":"https://twitch-embed-ts-docs.vercel.app/getting-started","keywords":["twitch-embed-api","twitch-player","twitch-embed"],"repository":{"url":"git+https://github.com/anivire/twitch-embed-ts.git"},"description":"Twitch Embed API Typescript wrapper","maintainers":[{"name":"anivire","email":"anivire.work@gmail.com"}],"readme":"# twitch-embed-ts\r\n\r\n![Logo](logo.png)\r\n\r\n<center>Typescript Wrapper for Twitch Embed player / chat, based on twitch embed API</center><br/>\r\n\r\n## Links\r\n\r\n📚 View wrapper [docs](https://twitch-embed-ts-docs.vercel.app/getting-started),<br/>\r\n📖 View official twitch [docs](https://dev.twitch.tv/docs/embed/)\r\n\r\n\r\n## Intallation \r\n```bash\r\nnpm i @anivire/twitch-embed-ts\r\n# or\r\nyarn add @anivire/twitch-embed-ts\r\n```\r\n\r\n## Basic usage\r\nBe sure to add the official Twitch Embed or Player script to your `index.html` first:\r\n```html\r\n<script src=\"https://embed.twitch.tv/embed/v1.js\"></script>\r\n<!-- OR / AND -->\r\n<script src=\"https://player.twitch.tv/embed/v1.js\"></script>\r\n```\r\n\r\n### Creating new TwitchEmbed instance\r\n`TwitchEmbed` allows you to embed anything, including a player and/or chat. It also contains a `TwitchPlayer`, which can be interacted by calling `embed.getPlayer()`:\r\n```ts\r\nconst embed = new TwitchEmbed(\r\n    'twitch-embed', \r\n    options: {\r\n        width: '1280',\r\n        height: '720',\r\n        channel: 'anivire_',\r\n        parent: ['anivire.xyz']\r\n    });\r\n```\r\n\r\n1. First argument `TwitchEmbed` is the identifier for the `<div>` in which the Twitch player will be embedded as a `<iframe>`.\r\n\r\n2. Second argument is an object with player settings, which include parameters width, player height, and channel / video / collection, where channel has highest priority, meaning if both channel and video are specified, only channel (live) will be used.\r\n\r\n### Creating new TwitchPlayer instance\r\n`TwitchPlayer` allows you to embed only player, without chat:\r\n```ts\r\nconst player = new TwitchPlayer(\r\n    'twitch-player', \r\n    options: {\r\n        width: '1280',\r\n        height: '720',\r\n        video: '2064229582',\r\n        parent: ['anivire.xyz']\r\n    });\r\n```\r\n\r\nAll other info provided on wrapper [docs](https://twitch-embed-ts-docs.vercel.app/getting-started).","readmeFilename":"readme.md"}