The export command in Bash marks a variable so that it is passed into the environment of child processes (subshells and any programs launched from the shell), rather than remaining a purely local shell variable. This is how environment variables such as PATH, EDITOR, or application-specific settings are made available to programs and scripts that the shell executes, which is why it is used to set up environment variables for applications.
Community Discussion