Enqueue script: link not working in page source

it doesn’t open it when I click on the link in page source. It just refreshes the page source page

Are you sure? Sounds like you’re getting the source for a WordPress 404 page. My spidey senses detect this is the problem:

plugin_dir_url( 'front-end-editor/build/' ) . 'editor.js'

…which isn’t quite how it should be used (see the codex), and you end up with:

http://example.com/wp-content/plugins/front-end-editor/editor.js

…see how the path is now broken? (build has been stripped)

Instead, use plugins_url (see the codex):

plugins_url( 'front-end-editor/build/editor.js' )