[{"data":1,"prerenderedAt":575},["ShallowReactive",2],{"index":3,"_hello-hummingbird":76,"_basic-route":305},{"_path":4,"_dir":5,"_draft":6,"_partial":6,"_locale":5,"title":7,"description":8,"hero":9,"features":24,"ecosystem":52,"performance":59,"cta":62,"_id":70,"_type":71,"_source":72,"_file":73,"_stem":74,"_extension":75},"/","",false,"Hummingbird","Hummingbird is a cross-platform web server framework for Swift.",{"title":7,"description":10,"links":11},"The Web framework for Swift",[12,19],{"label":13,"icon":14,"trailing":15,"size":16,"to":17,"target":18},"Get started","i-heroicons-arrow-right-20-solid",true,"xl","https://docs.hummingbird.codes/2.0/documentation/hummingbird/gettingstarted","_blank",{"label":20,"icon":21,"size":16,"color":22,"to":23},"Example Projects","i-simple-icons-github","gray","/examples",{"title":25,"description":26,"items":27},"Create Better Backends with Swift","Hummingbird takes advantage of Swift to make it easy and enjoyable to create robust backends.",[28,32,36,40,44,48],{"title":29,"description":30,"icon":31},"Ergonomic Syntax","Hummingbird apps are easy to develop thanks to Swift's ergonomic syntax.","i-heroicons-light-bulb",{"title":33,"description":34,"icon":35},"Structured Concurrency","Embracing Structured Concurrency makes Hummingbird apps easy to build.\n","i-heroicons-shield-check",{"title":37,"description":38,"icon":39},"Lightweight","With a tiny memory footprint, Hummingbird is perfect for deploying on cloud services.\n","i-heroicons-server-stack",{"title":41,"description":42,"icon":43},"Thread and Memory Safe","Swift checks your apps for errors, making your code reliable even before you run it.","i-heroicons-magnifying-glass",{"title":45,"description":46,"icon":47},"Predictably Performant","Hummingbird makes your backends blazing fast, while ARC replaces garbage collection.","i-heroicons-rocket-launch",{"title":49,"description":50,"icon":51},"Cross-Platform","Swift runs on your platform. Linux, macOS, and iOS.","i-simple-icons-linux",{"title":53,"description":54,"links":55},"Every Package you need","Hummingbird comes with mature solutions for the common needs of all web applications.\n",[56],{"label":57,"icon":14,"trailing":15,"size":16,"to":58,"target":18},"Discover Packages","/ecosystem",{"title":60,"description":61},"Excellent Performance","Hummingbird uses a modern, high-performance web server that can handle tens of thousands of requests per second.\nAll of this while keeping your memory footprint extremely low.\n",{"title":63,"description":64,"links":65},"Join the Hummingbird Community","Join the Hummingbird community on Discord to get help, share your projects, and chat with other developers.\n",[66],{"label":67,"to":68,"leadingIcon":69,"size":16},"Join the Community","https://discord.gg/4twfgYqdat","i-simple-icons-discord","content:index.yml","yaml","content","index.yml","index","yml",{"_path":77,"_dir":5,"_draft":6,"_partial":15,"_locale":5,"title":78,"description":5,"body":79,"_type":300,"_id":301,"_source":72,"_file":302,"_stem":303,"_extension":304},"/_hello-hummingbird","Hello Hummingbird",{"type":80,"children":81,"toc":298},"root",[82,292],{"type":83,"tag":84,"props":85,"children":89},"element","pre",{"className":86,"code":87,"language":88,"meta":5,"style":5},"language-swift shiki shiki-themes material-theme-lighter github-light material-theme-palenight","import Hummingbird\n\nlet router = Router().get { req, context in\n    return \"Hello, Swift!\"\n}\nlet app = Application(router: router)\ntry await app.runService()\n","swift",[90],{"type":83,"tag":91,"props":92,"children":93},"code",{"__ignoreMap":5},[94,113,122,181,207,216,263],{"type":83,"tag":95,"props":96,"children":99},"span",{"class":97,"line":98},"line",1,[100,107],{"type":83,"tag":95,"props":101,"children":103},{"style":102},"--shiki-light:#39ADB5;--shiki-light-font-style:italic;--shiki-default:#D73A49;--shiki-default-font-style:inherit;--shiki-dark:#89DDFF;--shiki-dark-font-style:italic",[104],{"type":105,"value":106},"text","import",{"type":83,"tag":95,"props":108,"children":110},{"style":109},"--shiki-light:#E2931D;--shiki-default:#6F42C1;--shiki-dark:#FFCB6B",[111],{"type":105,"value":112}," Hummingbird\n",{"type":83,"tag":95,"props":114,"children":116},{"class":97,"line":115},2,[117],{"type":83,"tag":95,"props":118,"children":119},{"emptyLinePlaceholder":15},[120],{"type":105,"value":121},"\n",{"type":83,"tag":95,"props":123,"children":125},{"class":97,"line":124},3,[126,132,138,144,150,156,161,166,171,176],{"type":83,"tag":95,"props":127,"children":129},{"style":128},"--shiki-light:#F76D47;--shiki-default:#D73A49;--shiki-dark:#F78C6C",[130],{"type":105,"value":131},"let",{"type":83,"tag":95,"props":133,"children":135},{"style":134},"--shiki-light:#90A4AE;--shiki-default:#24292E;--shiki-dark:#BABED8",[136],{"type":105,"value":137}," router ",{"type":83,"tag":95,"props":139,"children":141},{"style":140},"--shiki-light:#39ADB5;--shiki-default:#D73A49;--shiki-dark:#89DDFF",[142],{"type":105,"value":143},"=",{"type":83,"tag":95,"props":145,"children":147},{"style":146},"--shiki-light:#6182B8;--shiki-default:#005CC5;--shiki-dark:#82AAFF",[148],{"type":105,"value":149}," Router",{"type":83,"tag":95,"props":151,"children":153},{"style":152},"--shiki-light:#39ADB5;--shiki-default:#24292E;--shiki-dark:#89DDFF",[154],{"type":105,"value":155},"()",{"type":83,"tag":95,"props":157,"children":158},{"style":134},[159],{"type":105,"value":160},".",{"type":83,"tag":95,"props":162,"children":163},{"style":146},[164],{"type":105,"value":165},"get",{"type":83,"tag":95,"props":167,"children":168},{"style":152},[169],{"type":105,"value":170}," {",{"type":83,"tag":95,"props":172,"children":173},{"style":134},[174],{"type":105,"value":175}," req, context ",{"type":83,"tag":95,"props":177,"children":178},{"style":102},[179],{"type":105,"value":180},"in\n",{"type":83,"tag":95,"props":182,"children":184},{"class":97,"line":183},4,[185,190,196,202],{"type":83,"tag":95,"props":186,"children":187},{"style":102},[188],{"type":105,"value":189},"    return",{"type":83,"tag":95,"props":191,"children":193},{"style":192},"--shiki-light:#39ADB5;--shiki-default:#032F62;--shiki-dark:#89DDFF",[194],{"type":105,"value":195}," \"",{"type":83,"tag":95,"props":197,"children":199},{"style":198},"--shiki-light:#91B859;--shiki-default:#032F62;--shiki-dark:#C3E88D",[200],{"type":105,"value":201},"Hello, Swift!",{"type":83,"tag":95,"props":203,"children":204},{"style":192},[205],{"type":105,"value":206},"\"\n",{"type":83,"tag":95,"props":208,"children":210},{"class":97,"line":209},5,[211],{"type":83,"tag":95,"props":212,"children":213},{"style":152},[214],{"type":105,"value":215},"}\n",{"type":83,"tag":95,"props":217,"children":219},{"class":97,"line":218},6,[220,224,229,233,238,243,248,253,258],{"type":83,"tag":95,"props":221,"children":222},{"style":128},[223],{"type":105,"value":131},{"type":83,"tag":95,"props":225,"children":226},{"style":134},[227],{"type":105,"value":228}," app ",{"type":83,"tag":95,"props":230,"children":231},{"style":140},[232],{"type":105,"value":143},{"type":83,"tag":95,"props":234,"children":235},{"style":146},[236],{"type":105,"value":237}," Application",{"type":83,"tag":95,"props":239,"children":240},{"style":152},[241],{"type":105,"value":242},"(",{"type":83,"tag":95,"props":244,"children":245},{"style":146},[246],{"type":105,"value":247},"router",{"type":83,"tag":95,"props":249,"children":250},{"style":152},[251],{"type":105,"value":252},":",{"type":83,"tag":95,"props":254,"children":255},{"style":134},[256],{"type":105,"value":257}," router",{"type":83,"tag":95,"props":259,"children":260},{"style":152},[261],{"type":105,"value":262},")\n",{"type":83,"tag":95,"props":264,"children":266},{"class":97,"line":265},7,[267,272,277,282,287],{"type":83,"tag":95,"props":268,"children":269},{"style":102},[270],{"type":105,"value":271},"try",{"type":83,"tag":95,"props":273,"children":274},{"style":102},[275],{"type":105,"value":276}," await",{"type":83,"tag":95,"props":278,"children":279},{"style":134},[280],{"type":105,"value":281}," app.",{"type":83,"tag":95,"props":283,"children":284},{"style":146},[285],{"type":105,"value":286},"runService",{"type":83,"tag":95,"props":288,"children":289},{"style":152},[290],{"type":105,"value":291},"()\n",{"type":83,"tag":293,"props":294,"children":295},"style",{},[296],{"type":105,"value":297},"html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}",{"title":5,"searchDepth":115,"depth":115,"links":299},[],"markdown","content:_hello-hummingbird.md","_hello-hummingbird.md","_hello-hummingbird","md",{"_path":306,"_dir":5,"_draft":6,"_partial":15,"_locale":5,"title":307,"description":5,"body":308,"_type":300,"_id":572,"_source":72,"_file":573,"_stem":574,"_extension":304},"/_basic-route","Basic Route",{"type":80,"children":309,"toc":570},[310,566],{"type":83,"tag":84,"props":311,"children":313},{"className":86,"code":312,"language":88,"meta":5,"style":5},"import Hummingbird\nimport Meow // From MongoKitten\n\nrouter.get(\"/videos/:id\") { req, context in\n  let id = try context.parameters.require(\n    \"id\",\n    as: Reference\u003CVideo>.self\n  )\n  return try await id.resolve(in: db)\n}\n",[314],{"type":83,"tag":91,"props":315,"children":316},{"__ignoreMap":5},[317,328,346,353,400,437,459,500,509,558],{"type":83,"tag":95,"props":318,"children":319},{"class":97,"line":98},[320,324],{"type":83,"tag":95,"props":321,"children":322},{"style":102},[323],{"type":105,"value":106},{"type":83,"tag":95,"props":325,"children":326},{"style":109},[327],{"type":105,"value":112},{"type":83,"tag":95,"props":329,"children":330},{"class":97,"line":115},[331,335,340],{"type":83,"tag":95,"props":332,"children":333},{"style":102},[334],{"type":105,"value":106},{"type":83,"tag":95,"props":336,"children":337},{"style":109},[338],{"type":105,"value":339}," Meow",{"type":83,"tag":95,"props":341,"children":343},{"style":342},"--shiki-light:#90A4AE;--shiki-light-font-style:italic;--shiki-default:#6A737D;--shiki-default-font-style:inherit;--shiki-dark:#676E95;--shiki-dark-font-style:italic",[344],{"type":105,"value":345}," // From MongoKitten\n",{"type":83,"tag":95,"props":347,"children":348},{"class":97,"line":124},[349],{"type":83,"tag":95,"props":350,"children":351},{"emptyLinePlaceholder":15},[352],{"type":105,"value":121},{"type":83,"tag":95,"props":354,"children":355},{"class":97,"line":183},[356,361,365,369,374,379,383,388,392,396],{"type":83,"tag":95,"props":357,"children":358},{"style":134},[359],{"type":105,"value":360},"router.",{"type":83,"tag":95,"props":362,"children":363},{"style":146},[364],{"type":105,"value":165},{"type":83,"tag":95,"props":366,"children":367},{"style":152},[368],{"type":105,"value":242},{"type":83,"tag":95,"props":370,"children":371},{"style":192},[372],{"type":105,"value":373},"\"",{"type":83,"tag":95,"props":375,"children":376},{"style":198},[377],{"type":105,"value":378},"/videos/:id",{"type":83,"tag":95,"props":380,"children":381},{"style":192},[382],{"type":105,"value":373},{"type":83,"tag":95,"props":384,"children":385},{"style":152},[386],{"type":105,"value":387},")",{"type":83,"tag":95,"props":389,"children":390},{"style":152},[391],{"type":105,"value":170},{"type":83,"tag":95,"props":393,"children":394},{"style":134},[395],{"type":105,"value":175},{"type":83,"tag":95,"props":397,"children":398},{"style":102},[399],{"type":105,"value":180},{"type":83,"tag":95,"props":401,"children":402},{"class":97,"line":209},[403,408,413,417,422,427,432],{"type":83,"tag":95,"props":404,"children":405},{"style":128},[406],{"type":105,"value":407},"  let",{"type":83,"tag":95,"props":409,"children":410},{"style":134},[411],{"type":105,"value":412}," id ",{"type":83,"tag":95,"props":414,"children":415},{"style":140},[416],{"type":105,"value":143},{"type":83,"tag":95,"props":418,"children":419},{"style":102},[420],{"type":105,"value":421}," try",{"type":83,"tag":95,"props":423,"children":424},{"style":134},[425],{"type":105,"value":426}," context.parameters.",{"type":83,"tag":95,"props":428,"children":429},{"style":146},[430],{"type":105,"value":431},"require",{"type":83,"tag":95,"props":433,"children":434},{"style":152},[435],{"type":105,"value":436},"(\n",{"type":83,"tag":95,"props":438,"children":439},{"class":97,"line":218},[440,445,450,454],{"type":83,"tag":95,"props":441,"children":442},{"style":192},[443],{"type":105,"value":444},"    \"",{"type":83,"tag":95,"props":446,"children":447},{"style":198},[448],{"type":105,"value":449},"id",{"type":83,"tag":95,"props":451,"children":452},{"style":192},[453],{"type":105,"value":373},{"type":83,"tag":95,"props":455,"children":456},{"style":134},[457],{"type":105,"value":458},",\n",{"type":83,"tag":95,"props":460,"children":461},{"class":97,"line":265},[462,467,471,476,481,486,491,495],{"type":83,"tag":95,"props":463,"children":464},{"style":146},[465],{"type":105,"value":466},"    as",{"type":83,"tag":95,"props":468,"children":469},{"style":152},[470],{"type":105,"value":252},{"type":83,"tag":95,"props":472,"children":473},{"style":134},[474],{"type":105,"value":475}," Reference",{"type":83,"tag":95,"props":477,"children":478},{"style":140},[479],{"type":105,"value":480},"\u003C",{"type":83,"tag":95,"props":482,"children":483},{"style":134},[484],{"type":105,"value":485},"Video",{"type":83,"tag":95,"props":487,"children":488},{"style":140},[489],{"type":105,"value":490},">",{"type":83,"tag":95,"props":492,"children":493},{"style":134},[494],{"type":105,"value":160},{"type":83,"tag":95,"props":496,"children":497},{"style":128},[498],{"type":105,"value":499},"self\n",{"type":83,"tag":95,"props":501,"children":503},{"class":97,"line":502},8,[504],{"type":83,"tag":95,"props":505,"children":506},{"style":152},[507],{"type":105,"value":508},"  )\n",{"type":83,"tag":95,"props":510,"children":512},{"class":97,"line":511},9,[513,518,522,526,531,536,540,545,549,554],{"type":83,"tag":95,"props":514,"children":515},{"style":102},[516],{"type":105,"value":517},"  return",{"type":83,"tag":95,"props":519,"children":520},{"style":102},[521],{"type":105,"value":421},{"type":83,"tag":95,"props":523,"children":524},{"style":102},[525],{"type":105,"value":276},{"type":83,"tag":95,"props":527,"children":528},{"style":134},[529],{"type":105,"value":530}," id.",{"type":83,"tag":95,"props":532,"children":533},{"style":146},[534],{"type":105,"value":535},"resolve",{"type":83,"tag":95,"props":537,"children":538},{"style":152},[539],{"type":105,"value":242},{"type":83,"tag":95,"props":541,"children":542},{"style":146},[543],{"type":105,"value":544},"in",{"type":83,"tag":95,"props":546,"children":547},{"style":152},[548],{"type":105,"value":252},{"type":83,"tag":95,"props":550,"children":551},{"style":134},[552],{"type":105,"value":553}," db",{"type":83,"tag":95,"props":555,"children":556},{"style":152},[557],{"type":105,"value":262},{"type":83,"tag":95,"props":559,"children":561},{"class":97,"line":560},10,[562],{"type":83,"tag":95,"props":563,"children":564},{"style":152},[565],{"type":105,"value":215},{"type":83,"tag":293,"props":567,"children":568},{},[569],{"type":105,"value":297},{"title":5,"searchDepth":115,"depth":115,"links":571},[],"content:_basic-route.md","_basic-route.md","_basic-route",1775478208417]