Skip to content

Commit

Permalink
Updated README.md 📝
Browse files Browse the repository at this point in the history
  • Loading branch information
MarketingPip authored Jul 15, 2024
1 parent 2995613 commit 7d49336
Showing 1 changed file with 4 additions and 25 deletions.
29 changes: 4 additions & 25 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,20 +29,17 @@ This is a basic JavaScript library for fetching & parsing M3U files from a URL o
## Example usage


> Note: Any errors will be returned in a JSON key called <code>iptv_parser_error</code>

### Parse M3U8 from URL

```js
import {ParseM3U} from 'https://cdn.jsdelivr.net/gh/MarketingPipeline/IPTV-Parser.js/dist/iptv-parser.min.js';
import {ParseM3U} from 'https://cdn.jsdelivr.net/gh/MarketingPipeline/IPTV-Parser.js@latest/dist/iptv-parser.min.js';

async function Fetch_IPTV_Links() {
try {
let IPTV_Results = ParseM3U(`https://raw.githubusercontent.com/iptv-org/iptv/master/streams/us_pluto.m3u`, "URL")
let IPTV_Results = ParseM3U(`https://raw.githubusercontent.com/iptv-org/iptv/master/streams/us_pluto.m3u`)
console.log(await IPTV_Results)
} catch (err) {
// console.error(err);
console.error(err);
}
}
Fetch_IPTV_Links()
Expand All @@ -53,7 +50,7 @@ will return a JSON object of parsed results.
### Parse M3U8 from string

```js
import {ParseM3U} from 'https://cdn.jsdelivr.net/gh/MarketingPipeline/IPTV-Parser.js/dist/iptv-parser.min.js';
import {ParseM3U} from 'https://cdn.jsdelivr.net/gh/MarketingPipeline/IPTV-Parser.js@latest/dist/iptv-parser.min.js';

async function Parse_M3U_String() {
try {
Expand All @@ -74,24 +71,6 @@ Parse_M3U_String()

will return a JSON object of parsed results.

<br>


## CDN

### URL

https://cdn.jsdelivr.net/gh/MarketingPipeline/IPTV-Parser.js/dist/iptv-parser.min.js

### Import

import {ParseM3U} from 'https://cdn.jsdelivr.net/gh/MarketingPipeline/IPTV-Parser.js/dist/iptv-parser.min.js';






## Contributing ![GitHub](https://img.shields.io/github/contributors/MarketingPipeline/IPTV-Parser.js)

Expand Down

0 comments on commit 7d49336

Please sign in to comment.