Plugin Script
The second file of a plugin is the script file (plugin-script.js).
This file contains the logic to fetch, parse, and serve content from the plugin's source.
javascript
async function search(query) {
// code...
}
async function fetchEpisodes(id) {
// code...
}
async function fetchSources(id) {
// code...
}
return {
search,
fetchInfo,
fetchEpisodes,
fetchSources,
};Detailed Function Guides
- Search – How to implement the
searchfunction and its return format. - Fetch Episodes – Guide for
fetchEpisodesand expected results. - Fetch Sources – Details on
fetchSourcesand streaming data format.
IMPORTANT
Make sure each function strictly follows the expected return format to ensure compatibility with Mojuru.
