Skip to content

rosiecowling/govuk-content-best-practices

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

37 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

GOV.UK Content Best Practices

This repository hosts snapshots of gov.uk pages acting as examples of pages using content best practices.

Adding new pages manually

  • Navigate to the /snapshots dir and create a new file, here's how
  • The new file name should be <words-separated-with-hyphens>.html eg example-content.html
  • Paste the contents of the template file there.
  • Open the original page that you want to take a snapshot of and copy either <div id='whitehall-wrapper'> or <div id='whitehall-wrapper'> tag with its contents. You can do it by finding those elements via developer tools.
  • Replace <div id="placeholder">REPLACE THIS WHOLE DIV WITH PASTED CONTENT</div> with everything you've copied in the step above.
  • Open a pull request with the new file explaining the changes
  • Someone will review the changes and merge them to the gh-pages branch, which will make the new page available at http://alphagov.github.io/govuk-content-best-practices/snapshots/{your-file-name}.html

Adding new pages automatically

  • Update the list of links in exec/crawl.rb
  • run ruby exec/crawl.rb

Alternatively you can use the Crawler class in ruby:

Crawler.new(["https://gov.uk/something"], persist_to: '/tmp').run

About

Great examples of content publishing on GOV.UK.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • HTML 90.5%
  • Roff 9.2%
  • Ruby 0.3%