def add_node_js_binary
    return [] if node_js_preinstalled?

    if Pathname(app_path).join("package.json").exist? ||
         bundler.has_gem?('execjs') ||
         bundler.has_gem?('webpacker')

      version = @node_installer.version
      old_version = @metadata.fetch("default_node_version") { version }

      # Make available for `rake assets:precompile` and other sub-shells
      ENV["UV_USE_IO_URING"] ||= "0"
      # Make available to future buildpacks (export), but not runtime (profile.d)
      set_export_default "UV_USE_IO_URING", "0"

      if version != version
        warn(<<~WARNING, inline: true)
          Default version of Node.js changed (#{old_version} to #{version})
        WARNING
      end

      warn(<<~WARNING, inline: true)
        Installing a default version (#{version}) of Node.js.
        This version is not pinned and can change over time, causing unexpected failures.

        Heroku recommends placing the `heroku/nodejs` buildpack in front of
        `heroku/ruby` to install a specific version of node:

        https://devcenter.heroku.com/articles/ruby-support#node-js-support
      WARNING

      [@node_installer.binary_path]
    else
      []
    end
  end
decides if we need to install the node.js binary
@note execjs will blow up if no JS RUNTIME is detected and is loaded.
@return [Array] the node.js binary path if we need it or an empty Array