Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Modify the Flarum UI
<script type="text/javascript">
var thisHackInterval = setInterval(function(){
// Check if app is available yet
if (typeof(app) == "object")
{
// Set app routes to whatever I need
// This will repaint the DOM automatically
app.routes.settings.path = "https://my.laravel.site/preferences";
// Remove navigation elements I don't want
document.querySelector("li.item-logOut").remove();
document.querySelector("li.Dropdown-separator").remove();
clearInterval(thisHackInterval);
}
}, 500);
</script>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment