Rails Generators

Rapid Rails Themes ships with a bunch of Rails generators that create complete pages to save you hours of work. Generally, each generator will be able to create multiple variations of the given type of generator. This is achieved by supplying the --variant=n switch, with n being the number of the variant you want to generate. The default variant is 1, and ommitting the switch falls back to variant 1.

Available Generators

You can always get a list of current generators available to run by running the following snippet:

bin/rails g | grep 'rrt'
  • rails generate rrt:install

    Installs the theme files in your app, and hooks everything up. Just run this command and you're done.

  • rails generate rrt:customize

    Generates the customizable rrt.css.scss and rrt.js file that you can use to override / tweak the theme variables and includes.

  • rails generate rrt:dashboard_pages CONTROLLER_NAME ACTION_NAME --variant=1

    Generates the Dashboard template at app/views/CONTROLLER_NAME/ACTION_NAME

  • rails generate rrt:pricing_pages CONTROLLER_NAME ACTION_NAME --variant=1

    Generates a pricing style view at app/views/CONTROLLER_NAME/ACTION_NAME

  • rails generate rrt:error_pages

    Generates standard Error pages for 403, 404, 422 and 500 statuses at public/.

  • rails generate rrt:devise

    Generates the Rapid Rails Themes custom Devise views and Email templates into your application.

  • rails generate rrt:error_pages

    Generates the Custom error pages into the /public directory of your application.

  • rails generate rrt:legal_pages

    Generates the Privacy and Terms of Services page template at app/views/legal/terms_of_service.erb and app/views/legal/privacy.erb

  • rails generate rrt:faq_pages CONTROLLER_NAME ACTIONS_NAME --variant=1

    Generates the FAQ page variant template at app/views/CONTROLLER_NAME/ACTION_NAME.

  • rails generate rrt:landing_pages CONTROLLER_NAME ACTIONS_NAME --variant=1

    Generates the Landing page variant template at app/views/CONTROLLER_NAME/ACTION_NAME.

  • rails generate rrt:pricing_pages CONTROLLER_NAME ACTIONS_NAME --variant=1

    Generates the Pricing page variant template at app/views/CONTROLLER_NAME/ACTION_NAME.

  • rails generate rrt:user_account_pages CONTROLLER_NAME ACTIONS_NAME

    Generates the User account page variant template, controllers and partials at app/views/CONTROLLER_NAME/ACTION_NAME. Routes will also be created to route from /user

  • rails generate rrt:analytics_dashboard_pages CONTROLLER_NAME ACTION_NAME`

    Generates the Analytics Dashboard template at app/views/CONTROLLER_NAME/ACTION_NAME

  • rails generate rrt:analytics_detail_pages CONTROLLER_NAME ACTION_NAME`

    Generates the Analytics Detail template at app/views/CONTROLLER_NAME/ACTION_NAME

  • rails generate rrt:blog_post_pages CONTROLLER_NAME ACTION_NAME`

    Generates the Blog Post template at app/views/CONTROLLER_NAME/ACTION_NAME

  • rails generate rrt:blog_archive_pages CONTROLLER_NAME ACTION_NAME

    Generates the Blog Archive template at app/views/CONTROLLER_NAME/ACTION_NAME

  • rails generate rrt:content_blocks

    Copies all of the content blocks into your projects under the app/views/content_blocks directory.