#Rails Generators
KISO 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 'kiso_themes'
Command | Description |
---|---|
install | Installs the theme files in your app, and hooks everything up. Just run this command and you're done. |
customize | Generates the customizable rrt.css.scss and rrt.js file that you can use to override / tweak the theme variables and includes. |
dashboard_pages CONTROLLER_NAME ACTION_NAME --variant=1 | Generates the Dashboard template at app/views/CONTROLLER_NAME/ACTION_NAME |
pricing_pages CONTROLLER_NAME ACTION_NAME --variant=1 | Generates a pricing style view at app/views/CONTROLLER_NAME/ACTION_NAME |
error_pages | Generates standard Error pages for 403, 404, 422 and 500 statuses at public/ . |
devise | Generates the Rapid Rails Themes custom Devise views and Email templates into your application. |
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 |
faq_pages CONTROLLER_NAME ACTIONS_NAME --variant=1 | Generates the FAQ page variant template at app/views/CONTROLLER_NAME/ACTION_NAME . |
landing_pages CONTROLLER_NAME ACTIONS_NAME --variant=1 | Generates the Landing page variant template at app/views/CONTROLLER_NAME/ACTION_NAME . |
pricing_pages CONTROLLER_NAME ACTIONS_NAME --variant=1 | Generates the Pricing page variant template at app/views/CONTROLLER_NAME/ACTION_NAME . |
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 |
analytics_dashboard_pages CONTROLLER_NAME ACTION_NAME | Generates the Analytics Dashboard template at app/views/CONTROLLER_NAME/ACTION_NAME |
analytics_detail_pages CONTROLLER_NAME ACTION_NAME | Generates the Analytics Detail template at app/views/CONTROLLER_NAME/ACTION_NAME |
blog_post_pages CONTROLLER_NAME ACTION_NAME | Generates the Blog Post template at app/views/CONTROLLER_NAME/ACTION_NAME |
blog_archive_pages CONTROLLER_NAME ACTION_NAME | Generates the Blog Archive template at app/views/CONTROLLER_NAME/ACTION_NAME |
content_blocks | Copies all of the content blocks into your projects under the app/views/content_blocks directory. |