These days in the NWJS is OK to access the outside network, you can see the official documents, otherwise really want to cry no tears, can't find the relevant documents can not solve the problem.
Mainly talk about how the page transparent, there is a white screen flash problem it.
Main tools:
Angularjs+node+nw.js to develop and transmit the way data is displayed
Official documents:
In the HTML page implementation:
<body style= "Background-color:rgba (0,0,0,0)" >
Implemented in the Package.json file
"Window": {
"Frame": false,
"Transparent": true
}
OK can be transparent, but is displayed when there is a flashing white screen, white screen on a flash, how to do
Continue to add files in Package.json
"Show": false
Fill in the following code into the app file:
var GUI = require (' Nw.gui ');
var win = GUI. Window.get ();
Win.show ();
The problem is solved, very happy ah.
Why is that so, I think:
Nwjs the height of the page, the width, whether the status bar and other information are placed in the Package.json File window object, the page changes need to be modified window properties.
First let the window not display, and then the onload when the window is displayed, onload is in the DOM and JS loaded when the display, so it will not be white screen.
Nwjs Resolve page transparency, display white screen on startup