Project

joofaq

0.0
No commit activity in last 3 years
No release in over 3 years
FAQ page template building gem
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Runtime

~> 3.1
= 1.6.8
 Project Readme

Joofaq

Joofaq is a FAQ page template building gem. In two easy steps you can have a FAQ page up and running on your rails app with questions and sections easily customizable from a yaml file.

Installation

Add this line to your application's Gemfile:

gem 'joofaq'

Usage

After adding joofaq to your Gemfile, run the joofaq gem generator command:

rails generate joofaq

This will create a faq.yml file in your db/ directory. To add new sections and questions, follow the format shown in the faq.yml:

First_category_name_here:
- subtitle: first_category_subtitle_here
- q: question_1_text_here
  a: answer_1_text_here

Subtitles are optional and you can add as many questions as you need. Remember, this is a yaml file so format (especially indentation) is important for it to work properly.

The generator also created several view files in a new app/views/faq/ directory. This gives you access to the views so that you can change the styling as you please.

You can now view your app's faq at '/faq' (localhost:3000/faq). Can you change this routing in your config/routes.rb file.

Contributing

  1. Fork it
  2. Create your feature branch (git checkout -b my-new-feature)
  3. Commit your changes (git commit -am 'Add some feature')
  4. Push to the branch (git push origin my-new-feature)
  5. Create new Pull Request