If you're looking to create an executable from your Node.js project, https://www.npmjs.com/package/pkg could be a helpful tool.
With this command line interface, you can package your Node.js project into an executable file that can run on devices without Node.js installed.
A key feature is its handling of dependencies:
Pkg scans your source code, identifies required modules, and includes them in the final executable file during the packaging process.
Keep in mind that managing webdriver executables like chromedriver or geckodriver may require manual inclusion in your final executable.
Furthermore, staying updated with browser versions is crucial for distributing your application. Different users will have varying browser versions, necessitating timely updates and redistribution of relevant drivers.