Serverless Architecture

WebSuite uses Edge Functions architecture with Bun.js runtime, providing a global, high-performance, and secure foundation for your content.

Why Serverless?

Built on Edge Functions architecture for unmatched performance and scalability

Edge Rendering

Unlike traditional servers, our Edge Functions run on a global edge network. Every request is handled by the data center closest to the user, ensuring near-zero latency. HTML is generated dynamically at the edge, combining static templates with dynamic content.

Zero Cold Starts

Edge Functions with Bun.js runtime provide instant startup times with minimal cold start delays. Your functions execute immediately, every time, anywhere in the world.

Universal Feed Parser

The Worker acts as a universal adapter. It fetches RSS feeds from Substack, YouTube, Podcast hosts, and Event platforms like Meetup, parses the XML, and transforms it into a unified JSON structure. This allows you to use any content source without changing your frontend code.

HTMX Native

The backend is aware of HTMX. When it detects an `HX-Request` header, it returns only the necessary HTML fragment (like a card or a list) instead of the full page. This creates a Single Page Application (SPA) feel without the complexity of client-side frameworks.

Smart Caching

To minimize latency and avoid hitting rate limits on external APIs, the Worker implements a smart caching strategy. Parsed feed data is cached using the Cache API and KV storage, ensuring that your site remains fast and available even if the source feeds are slow or down.

Cost Effective

Pay only for what you use. No idle server costs, no infrastructure management. Most edge platforms offer generous free tiers (100,000+ requests per day), perfect for most projects. Scale automatically without worrying about server capacity.

Worker Logic Snippet

// Example of Edge Routing Logic
export default {
  async fetch(req, env) {
    const url = new URL(req.url);
    
    // 1. HTMX Detection
    const isHtmx = req.headers.get("HX-Request") === "true";
    
    // 2. Route Handling
    if (url.pathname === "/api/posts") {
      const posts = await getCachedRSS(env.SUBSTACK_URL);
      
      if (isHtmx) {
        // Return HTML fragment for HTMX
        return generatePostCards(posts);
      }
      
      // Return JSON for API
      return Response.json(posts);
    }
    
    // 3. Static Asset Fallback
    return env.ASSETS.fetch(req);
  }
}

Ready to Go Serverless?

Experience the power of edge computing with WebSuite. Get started in minutes with our serverless architecture.

Get Started