Spaces:
Running
Running
Download script.js from Talha24/deepsite-explorer: direct link, hf CLI and curl.
- Browser
- Download file 712 Bytes
-
https://huggingface.co/spaces/Talha24/deepsite-explorer/resolve/main/script.js
- Command line
-
hf download hf://spaces/Talha24/deepsite-explorer/script.js
-
curl -L -o script.js https://huggingface.co/spaces/Talha24/deepsite-explorer/resolve/main/script.js
712 Bytes
| // Main JavaScript file for common functionality | |
| document.addEventListener('DOMContentLoaded', () => { | |
| // Initialize feather icons | |
| if (typeof feather !== 'undefined') { | |
| feather.replace(); | |
| } | |
| console.log('DeepSite Explorer loaded'); | |
| }); | |
| // CurseForge API wrapper | |
| async function fetchCurseForgeData(endpoint) { | |
| try { | |
| const response = await fetch(`https://api.curseforge.com/v1/${endpoint}`, { | |
| headers: { | |
| 'x-api-key': 'YOUR_CURSEFORGE_API_KEY' // Replace with actual API key | |
| } | |
| }); | |
| return await response.json(); | |
| } catch (error) { | |
| console.error('CurseForge API error:', error); | |
| return null; | |
| } | |
| } | |