-
Notifications
You must be signed in to change notification settings - Fork 6
Adding a new page
Brian Hurst edited this page May 19, 2021
·
9 revisions
Located at _layouts/page.html
, this is the template that is most frequently used on beta.ada.gov. It is responsible for creating content pages like Intro to ADA.
In order to preview your changes on your local machine it is necessary to have the Jekyll development server running. Follow the instructions in the README to learn how to run the application.
- Switch to the
main
branch - Click the "Fetch" button
- Click the
main
branch button again - Give the branch a unique name and click the "New branch" button
Within your project folder:
- Run
git checkout main
- Run
git pull
- Run
git checkout -b new-unique-page
- Within Atom, create a new file in the
_pages
directory. Be sure to create the file within a folder that will allow it to be easily found in the future. For example all of the guide pages (such as Intro to ADA) are found within_/pages/guides/
. Be sure to give the file a unique name as well, using the formatmy-new-page.md
(no spaces or special characters). - Copy and paste the required front matter in as your starting point, replacing with your own unique content:
---
title: Introduction to the Americans with Disabilities Act
permalink: /guides/intro-to-ada/
---
Hello world!
- Using markdown, add your content to the markdown file.
- For more advanced content, such as content nested within an accordion, reference the documented markdown widgets.
- In the event that a component is need that does not already have a custom markdown widget, reference the USWDS documentation to copy the HTML markup of the desired component.
- Click the "Stage All" button in the "Unstaged Changes" bar
- Once you've staged your changes, enter a commit message. Finalize by clicking the Commit button.
- When you're ready to share your changes to GitHub, click the Push button in the Status Bar
- Visit the beta-ada repo to create a new Pull request.
Within your project folder:
- Run
git add .
- Run
git commit -m "First draft of new page"
- Run
git push origin new-unique-page
- Visit the beta-ada repo to create a new Pull request.