docs: original-fs module

This commit is contained in:
Cheng Zhao 2014-11-12 11:58:03 +08:00
parent 90c24de0f0
commit bd1f0e78a8

View file

@ -95,6 +95,17 @@ var win = new BrowserWindow({width: 800, height: 600});
win.loadUrl('asar:/path/to/example.asar/static/index.html');
```
### Treating `asar` archive as normal file
For some cases like verifying the `asar` archive's checksum, we need to read the
content of `asar` archive as file. For this purpose you can use the built-in
`original-fs` module which provides original `fs` APIs without `asar` support:
```javascript
var originalFs = require('original-fs');
originalFs.readFileSync('/path/to/example.asar');
```
## Limitations on Node API
Even though we tried hard to make `asar` archives in the Node API work like