{"id":15038214,"url":"https://github.com/vaporexampleslab/quickstart-bootstrap-basic","last_synced_at":"2026-02-13T00:02:15.110Z","repository":{"id":133115020,"uuid":"174043871","full_name":"VaporExamplesLab/quickstart-bootstrap-basic","owner":"VaporExamplesLab","description":"Minimal Vapor Bootstrap example project.","archived":false,"fork":false,"pushed_at":"2020-05-27T22:08:21.000Z","size":101,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-03-13T13:13:57.976Z","etag":null,"topics":["server-side-swift","vapor","vapor-3","vapor-example"],"latest_commit_sha":null,"homepage":"","language":"Swift","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/VaporExamplesLab.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2019-03-06T00:50:43.000Z","updated_at":"2023-11-11T23:18:10.000Z","dependencies_parsed_at":null,"dependency_job_id":"971320af-3f08-4a15-a16e-8acddd3247ad","html_url":"https://github.com/VaporExamplesLab/quickstart-bootstrap-basic","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/VaporExamplesLab%2Fquickstart-bootstrap-basic","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/VaporExamplesLab%2Fquickstart-bootstrap-basic/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/VaporExamplesLab%2Fquickstart-bootstrap-basic/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/VaporExamplesLab%2Fquickstart-bootstrap-basic/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/VaporExamplesLab","download_url":"https://codeload.github.com/VaporExamplesLab/quickstart-bootstrap-basic/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243410446,"owners_count":20286396,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["server-side-swift","vapor","vapor-3","vapor-example"],"created_at":"2024-09-24T20:37:34.965Z","updated_at":"2026-02-13T00:02:15.051Z","avatar_url":"https://github.com/VaporExamplesLab.png","language":"Swift","funding_links":[],"categories":[],"sub_categories":[],"readme":"# [quickstart-bootstrap-basic][t]\n[t]:https://github.com/VaporExamplesLab/quickstart-bootstrap-basic\n\n\u003cp align=\"center\"\u003e\n    \u003ca href=\"http://docs.vapor.codes/3.0/\"\u003e\n        \u003cimg src=\"http://img.shields.io/badge/read_the-docs-2196f3.svg\" alt=\"Documentation\"\u003e\n    \u003c/a\u003e\n    \u003ca href=\"LICENSE\"\u003e\n        \u003cimg src=\"http://img.shields.io/badge/license-MIT-brightgreen.svg\" alt=\"MIT License\"\u003e\n    \u003c/a\u003e\n    \u003ca href=\"https://swift.org\"\u003e\n        \u003cimg src=\"http://img.shields.io/badge/swift-4.2-brightgreen.svg\" alt=\"Swift 4.2\"\u003e\n    \u003c/a\u003e\n\u003c/p\u003e\n\n\u003ca id=\"toc\"\u003e\u003c/a\u003e\n[Getting Started](#GettingStarted) •\n[Original Setup](#OriginalSetup) •\n[Resources](#Resources) \n\n## Getting Started \u003ca id=\"GettingStarted\"\u003e\u003c/a\u003e[▴](#toc)\n\n**Prerequisites**\n\n* [Install Xcode 10 ⇗](https://itunes.apple.com/us/app/xcode/id497799835?mt=12)\n* [Install homebrew ⇗](https://brew.sh/)\n* [Install vapor toolbox ⇗](https://docs.vapor.codes/3.0/install/macos/)\n\n**Download|Clone \u0026 Run**\n\nSteps to download repository:\n\n``` bash\n## go to your working directory\ncd \u003cyour-choosen-directory-path\u003e\n\n## download and unzip\nwget https://github.com/VaporExamplesLab/quickstart-bootstrap-basic/archive/master.zip\nunzip master.zip -d quickstart-bootstrap-basic\nrm master.zip     # remove download\n\ncd quickstart-bootstrap-basic-master\n\n# update dependencies \n# with `-y` yes to generate and open Xcode project\nvapor update -y\n```\n\nOr, alternate steps to clone repository instead of download:\n\n``` bash\n## go to your working directory\ncd \u003cyour-choosen-directory-path\u003e\n\n## either clone\n##    add --bare option for an unattached instance\ngit clone git@github.com:VaporExamplesLab/quickstart-bootstrap-basic.git \n\ncd quickstart-bootstrap-basic\n\n# update dependencies \n# with `-y` yes to generate and open Xcode project\nvapor update -y\n```\n\nSet Xcode scheme to \"Run \u003e My Mac\".\n\n![](README_files/XcodeScheme.png)\n\nClick the run button and check the results in a browser at `http://localhost:8080`.\n\n![](README_files/LandingPage.png)\n\n## Original Setup \u003ca id=\"OriginalSetup\"\u003e\u003c/a\u003e[▴](#toc)\n\nThe following steps were completed to create the `quickstart-bootstrap-basic` example. \n\n\n**Create Vapor Website Project**\n\nCreate a `quickstart-bootstrap-basic` project from the command line terminal:\n\n``` bash\nvapor new quickstart-bootstrap-basic --web\ncd quickstart-bootstrap-basic\n# add directory for README.md assets\nmkdir README_files \ntouch README_files/.git_keep # create file so folder is not empty for `git`  \n\n# update dependencies \n# with `-y` yes to generate and open Xcode project\nvapor update -y\n```\n\n**Add Bootstrap**\n\nUse the Bootstrap starter template. On [getbootstrap.com](getbootstrap.com) click the _`Get started`_ button and scroll down to _`Starter template`_ section. The `\u003cmeta\u003e`, `\u003clink\u003e` and `\u003cscript\u003e` are added to Resources/View/base.leaf in the Vapor project. The `#get(body)` is placed inside a Bootstrap container `\u003cdiv\u003e`\n\n_base.leaf_\n\n``` html\n\u003c!doctype html\u003e\n\u003chtml lang=\"en\"\u003e\n\u003chead\u003e\n    \u003c!-- Bootstrap required meta tags --\u003e\n    \u003cmeta charset=\"utf-8\"\u003e\n    \u003cmeta name=\"viewport\" content=\"width=device-width, initial-scale=1, shrink-to-fit=no\"\u003e\n\n    \u003c!-- Bootstrap CSS --\u003e\n    \u003clink rel=\"stylesheet\" href=\"https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/css/bootstrap.min.css\" integrity=\"sha384-ggOyR0iXCbMQv3Xipma34MD+dH/1fQ784/j6cY/iJTQUOhcWr7x9JvoRxT2MZw1T\" crossorigin=\"anonymous\"\u003e\n\n    \u003c!-- Application overriding CSS --\u003e\n\t\u003clink rel=\"stylesheet\" href=\"/styles/app.css\"\u003e\n\n    \u003ctitle\u003e#get(title)\u003c/title\u003e\n\u003c/head\u003e\n\u003cbody\u003e\n    \u003c!-- navigation to go here. --\u003e\n    \n    \u003c!-- mt-3: margin top `1rem` --\u003e\n    \u003cdiv class=\"container mt-3\"\u003e\n    #get(body)\n    \u003c/div\u003e\n    \n    \u003c!-- JavaScript to support various Bootstrap features --\u003e\n    \u003c!-- jQuery first, then Popper.js, then Bootstrap JS --\u003e\n    \u003cscript src=\"https://code.jquery.com/jquery-3.3.1.slim.min.js\" integrity=\"sha384-q8i/X+965DzO0rT7abK41JStQIAqVgRVzpbzo5smXKp4YfRvH+8abtTE1Pi6jizo\" crossorigin=\"anonymous\"\u003e\u003c/script\u003e\n    \u003cscript src=\"https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.14.7/umd/popper.min.js\" integrity=\"sha384-UO2eT0CpHqdSJQ6hJty5KVphtPhzWj9WO1clHTMGa3JDZwrnQq4sF86dIHNDz0W1\" crossorigin=\"anonymous\"\u003e\u003c/script\u003e\n    \u003cscript src=\"https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/js/bootstrap.min.js\" integrity=\"sha384-JjSmVgyd0p3pXB1rRibZUAYoIIy6OrQ6VrjIEaFf/nJGzIxFDsf4x0xIM+B07jRM\" crossorigin=\"anonymous\"\u003e\u003c/script\u003e\n\n\u003c/body\u003e\n\u003c/html\u003e\n```\n\nAdd navigation to _base.leaf_ above the `\u003cdiv\u003e` body container.\n\n``` html\n\u003c!-- navbar{-dark|-light|-primary} --\u003e\n\u003c!-- bg{-dark|-light|-primary} | style=\"background-color: #e3f2fd;\" --\u003e\n\u003cnav class=\"navbar navbar-expand-md navbar-dark bg-primary\"\u003e\n  \u003ca class=\"navbar-brand\" href=\"/\"\u003eBasic Example\u003c/a\u003e\n  \u003c!-- Button toggles navigation bar for small screen sizes.\n       Shows and hides the `navbarSupportedContent` section. --\u003e\n  \u003cbutton class=\"navbar-toggler\" type=\"button\"\n   data-toggle=\"collapse\" data-target=\"#navbarSupportedContent\"\n   aria-controls=\"navbarSupportedContent\" aria-expanded=\"false\"\n   aria-label=\"Toggle navigation\"\u003e\n    \u003cspan class=\"navbar-toggler-icon\"\u003e\u003c/span\u003e\n  \u003c/button\u003e\n  \u003c!-- Collapsable section for small screen. --\u003e\n  \u003cdiv class=\"collapse navbar-collapse\"\n   id=\"navbarSupportedContent\"\u003e\n    \u003c!-- Define a list of navigation `nav-item` links. --\u003e\n    \u003cul class=\"navbar-nav mr-auto\"\u003e\n      \u003cli class=\"nav-item #if(title == \"Hello, great to see you!\"){active}\"\u003e\n        \u003ca href=\"/hello/great to see you/\" class=\"nav-link\"\u003eOne\u003c/a\u003e\n      \u003c/li\u003e\n      \u003cli class=\"nav-item #if(title == \"Hello, again!\"){active}\"\u003e\n        \u003ca href=\"/hello/again/\" class=\"nav-link\"\u003eTwo\u003c/a\u003e\n      \u003c/li\u003e\n    \u003c/ul\u003e\n  \u003c/div\u003e\n\u003c/nav\u003e\n\n```\n\n## Resources \u003ca id=\"Resources\"\u003e\u003c/a\u003e[▴](#toc)\n\n* [Bootstrap ⇗](https://getbootstrap.com)\n* [Wenderlich: Beautifying Templated Websites with Leaf and Bootstrap ⇗](https://www.raywenderlich.com/1004734-beautifying-templated-websites-with-leaf-and-bootstrap)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvaporexampleslab%2Fquickstart-bootstrap-basic","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fvaporexampleslab%2Fquickstart-bootstrap-basic","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvaporexampleslab%2Fquickstart-bootstrap-basic/lists"}