0.0
The project is in a healthy, maintained state
SuperAdmin is a mountable Rails engine that provides a full-featured administration interface inspired by Administrate and ActiveAdmin, built for modern Rails 7+ applications.
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
2025
 Dependencies

Runtime

>= 0
>= 9.0
>= 7.1, < 9.0
 Project Readme

SuperAdmin

Gem Version CI Status Ruby Style Guide License

A modern, flexible administration engine for Rails applications

SuperAdmin is a mountable Rails engine that provides a full-featured administration interface inspired by Administrate and ActiveAdmin, built for modern Rails 7+ applications with Hotwire, Turbo, and Tailwind CSS.

SuperAdmin Dashboard

Quick Links: 📖 Documentation⚡ Features • 🚀 Quick Start • 🤝 Contributing


Why SuperAdmin?

  • Built for Rails 7+ - Takes full advantage of Hotwire, Turbo, and modern Rails features
  • ⚡ Fast by Default - Turbo-powered interactions without writing JavaScript
  • Beautiful UI - Modern, responsive design with Tailwind CSS
  • Easy to Customize - Simple DSL that doesn't get in your way
  • Batteries Included - Audit logging, CSV exports, and authorization built-in
  • Quick Setup - Get a full admin panel running in under 5 minutes

Status

In Active Development - This gem is currently in active development. APIs may change between versions. Production use is not recommended until v1.0 release.

Requirements

  • Ruby >= 3.2
  • Rails >= 7.1
  • ImportMap Rails (default in Rails 8+)

Installation

1. Add the Gem

gem "super_admin", "~> 0.2.0"

Then run:

bundle install

2. Install SuperAdmin

rails generate super_admin:install
rails db:migrate

3. Mount the Engine

Add to your config/routes.rb:

mount SuperAdmin::Engine => '/super_admin'

4. Generate Dashboards

# Generate dashboards for all models
rails generate super_admin:dashboard

# Or for a specific model
rails generate super_admin:dashboard User

5. Start Your Server

bin/dev

Visit /super_admin and you're done! 🎉

Quick Start

Customize a Dashboard

Edit the generated dashboard to control which attributes are displayed:

# app/dashboards/super_admin/user_dashboard.rb
module SuperAdmin
  class UserDashboard < BaseDashboard
    # Attributes shown in the table view
    def collection_attributes
      %i[id email name created_at]
    end

    # Attributes shown in the detail view
    def show_attributes
      %i[id email name role created_at updated_at posts]
    end

    # Attributes shown in the form
    def form_attributes
      %i[email name role bio]
    end
  end
end

Configure Authorization

In config/initializers/super_admin.rb:

SuperAdmin.configure do |config|
  # Use Pundit
  config.authorization_adapter = :pundit

  # Or custom authorization
  config.authorize_with do
    redirect_to root_path unless current_user&.admin?
  end

  # Number of records per page
  config.records_per_page = 20

  # Maximum nested depth for associations
  config.max_nested_depth = 3
end

Key Features

  • Full CRUD Operations - Create, read, update, delete with minimal configuration
  • Advanced Filtering - Search, filter, and sort with dynamic UI
  • CSV Exports - Background job processing with status tracking
  • Audit Logging - Track all admin activities automatically
  • Nested Associations - Smart form builder with configurable depth
  • Authorization - Pundit, CanCanCan, or custom authorization
  • Turbo Streams - Real-time updates without page reloads
  • Accessibility - WCAG 2.1 compliant with ARIA labels and keyboard navigation

📖 See all features

Documentation

Development

Setup

git clone https://github.com/ThibautBaissac/super_admin.git
cd super_admin
bundle install

Running Tests

bin/rails test

Code Quality

bin/rubocop

Testing with a Rails App

cd test/dummy
bin/rails db:seed
bin/dev
# Visit http://localhost:3000/super_admin/

Contributing

We welcome contributions! See CONTRIBUTING.md for guidelines.

  1. Fork the repository
  2. Create your feature branch (git checkout -b feat/my-feature)
  3. Write tests for your changes
  4. Run tests and linter (bin/rails test && bin/rubocop)
  5. Commit your changes (git commit -am 'Add new feature')
  6. Push to the branch (git push origin feat/my-feature)
  7. Create a Pull Request

License

SuperAdmin is released under the MIT License.

Support

Acknowledgments

SuperAdmin is inspired by:

  • Administrate - Thoughtbot's admin framework
  • ActiveAdmin - The Ruby on Rails framework for creating elegant backends

Made with ❤️ by Thibaut Baissac

⭐ Star this repo🐛 Report an issue