Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Speed up super admin dashboard #13147

Open
wants to merge 7 commits into
base: master
Choose a base branch
from

Conversation

dacook
Copy link
Member

@dacook dacook commented Feb 13, 2025

What? Why?

It takes so long to load because there's so many enterprises. We don't need to see those.

This has been bugging me since.. forever.

Also did some code cleanup, and removed some unused translation keys.
I tried to use gem i18n-tasks to discover unused keys, but it seemed too risky to clean up too many at once.

If code review passes, maybe it's worth running this past an instance manager too.

What should we test?

  • Go to the admin dashboard as super admin
  • go make a coffee It loads quickly!
  • Scroll to bottom to discover total number of enterprises and click through to browse them all.
  • All text on the admin dashboard page still displays correctly.

  • Go to the admin dashboard as enterprise admin with multiple enterprises (but less than 25)
  • Scroll to bottom, there's no "show all" link.

Release notes

Changelog Category (reviewers may add a label for the release notes):

  • User facing changes
  • API changes (V0, V1, DFC or Webhook)
  • Technical changes only
  • Feature toggled

The title of the pull request will be included in the release notes.

Dependencies

Documentation updates

Div is the default element in HAML, so we don't need to specify it.
I thought about reducing it further, but maybe people are used to having a large list. Let's see how this performs
I searched the codebase for these keys, but couldn't find them
The next ones look unused too.
I thought we had a plugin to help with that..
And check fo unused translations:

  bundle exec i18n-tasks unused -l en -f key-values | wc -l
  1277

Wow, really??
That brings the count down to 'only' 1057.

There's probably a lot of other keys that are dynamically generated, I did *not* review them all.
We could consider saving the output of this command to a todo file.
@dacook dacook self-assigned this Feb 13, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Code review 🔎
Development

Successfully merging this pull request may close these issues.

1 participant