How to inject customized JavaScript into Jira

I know that I can’t reload the issue page with Script Runner.
When a specific transition occurs, I want to reload the issue page with JavaScript.
Please recommend a good way. Thank you.