Is it okay to use nw.js for data collection? For example, click a button to automatically open a website, obtain the specified data, and then return to your own website.

  node.js, question

Currently only to open the website:

nw.Window.open('http://www.qq.com/', {}, (win)=>{
 
 win.showDevTools();
 win.on('loaded', function() {
 //This sentence is executed normally, which means that there is little problem in obtaining data.
 win.eval(null, "alert('asd')");
 
 //but I think loading js with nw.require will cause the program to crash
 // win.eval(null, "nw.require('http://tmdmphp.com/xxx.js')");
 
 //general nw.js programs can transmit data in this way.
 // nw.global.aa = 111;
 // alert(nw.global.aa);
 
 //But this sentence will cause the program to close directly.
 win.eval(null, "nw.global.aa = 111");
 alert(nw.global.aa);
 });
 
 });

I don’t think it should be a big problem to get the data.
I just don’t know if there is a more convenient way to load js.
Otherwise, we can onlydocument.createElement('script')The

The main problem is how to transfer the data to the page of your website after you get it.
nw.globalInwin.evalInside can’t use it.
localStorageIt can only exist under the domain name of www.qq.com.
openerObviously not, not with ordinarywindow.openOpen.

Shouldn’t I use itnw.jsTo achieve data collection? ? ?

I have never used nwjs before.

It is suggested to change to an Electron.