How to properly edit system files (as root) in GUI (and CLI) in Gnu/Linux?

You shouldn’t run an editor as root unless absolutely necessary; you should use sudoedit, or your desktop environment’s administrative features.

sudoedit

Once sudoedit is set up appropriately, you can do

SUDO_EDITOR="/opt/sublime_text/sublime_text -w" sudoedit yourfile

sudoedit will check that you’re allowed to do this, make a copy of the file that you can edit without changing ids manually, start your editor, and then, when the editor exits, copy the file back if it has been changed.

I’d suggest a function rather than an alias:

function susubl {
    export SUDO_EDITOR="/opt/sublime_text/sublime_text -w"
    sudoedit "$@"
}

although as Jeff Schaller pointed out, you can use env to put this in an alias and avoid changing your shell’s environment:

alias susubl='env SUDO_EDITOR="/opt/sublime_text/sublime_text -w" sudoedit'

The -w option ensures that the Sublime Text invocation waits until the files are closed before returning and letting sudoedit copy the files back.

Desktop environments (GNOME)

In GNOME (and perhaps other desktop environments), you can use any GIO/GVFS-capable editor, with the admin:// prefix; for example

gedit admin:///path/to/your/file

This will prompt for the appropriate authentication using PolKit, and then open the file for editing if the authentication was successful.