Convert Cloudflare Worker to Cloudflare Pages

This commit converts the entire Xget application from a Cloudflare Worker
to a Cloudflare Page, enabling static asset hosting while maintaining all
existing functionality.

Changes:
- Add functions/[[path]].js: Catch-all Pages Function handler
- Add public/index.html: Landing page with Xget information
- Update src/index.js: Export handleRequest for Pages Function import
- Update wrangler.toml: Configure for Pages deployment
- Update package.json: Change scripts to use Pages commands
- Update vitest.config.js: Include functions/ in coverage
- Update .github/workflows/depoly.yml: Deploy to Pages
- Update documentation: CLAUDE.md, README.md, README.en.md

The conversion maintains full backward compatibility with existing tests
and functionality. All caching strategies, security headers, and protocol
handling remain unchanged.
This commit is contained in:
Claude committed 2025-11-16 15:18:34 +00:00
1 parent f74850e5a2
commit eabf0782d4
10 files changed
+240 -35

No files matched your search

+1 -1
View File
@@ -19,7 +19,7 @@ export default defineWorkersConfig({
'*.config.js',
'*.config.ts'
],
include: ['src/**/*.js', 'src/**/*.ts'],
include: ['src/**/*.js', 'src/**/*.ts', 'functions/**/*.js', 'functions/**/*.ts'],
thresholds: {
global: {
branches: 80,