]> khamidou — GitHub mirrors - electron.git/commitdiff
docs: process.noAsar
authorCheng Zhao <zcbenz@gmail.com>
Tue, 1 Dec 2015 05:43:52 +0000 (13:43 +0800)
committerCheng Zhao <zcbenz@gmail.com>
Tue, 1 Dec 2015 05:43:52 +0000 (13:43 +0800)
docs/api/process.md
docs/tutorial/application-packaging.md

index 22fe452b0cadb3db4679a99cd8e69be4654d6e4c..620ad6dc931a4a01ed94440269f05802bbfd1484 100644 (file)
@@ -31,11 +31,18 @@ process.once('loaded', function() {
 });
 ```
 
+## Properties
+
+### `process.noAsar`
+
+Setting this to `true` can disable the support for `asar` archives in Node's
+built-in modules.
+
 ## Methods
 
 The `process` object has the following method:
 
-### `process.hang`
+### `process.hang()`
 
 Causes the main thread of the current process hang.
 
index c6e0ae3c41035de0c3890314dc1cb9fb2fc09230..b42a2f9298ba90bdefd5f7ba57179480c89a6866 100644 (file)
@@ -103,6 +103,14 @@ var originalFs = require('original-fs');
 originalFs.readFileSync('/path/to/example.asar');
 ```
 
+You can also set `process.noAsar` to `true` to disable the support for `asar` in
+the `fs` module:
+
+```javascript
+process.noAsar = true;
+fs.readFileSync('/path/to/example.asar');
+```
+
 ## Limitations on Node API
 
 Even though we tried hard to make `asar` archives in the Node API work like