]> git.codecow.com Git - nano-pow.git/commitdiff
Update README.
authorChris Duncan <chris@zoso.dev>
Sat, 14 Jun 2025 18:52:48 +0000 (11:52 -0700)
committerChris Duncan <chris@zoso.dev>
Sat, 14 Jun 2025 18:52:48 +0000 (11:52 -0700)
README.md

index f9448998dc1ea21f08882841e2a5c4185027a0e3..eed61d0dfb663d5a9a1cd435c0f083cfcf0d5158 100644 (file)
--- a/README.md
+++ b/README.md
@@ -8,7 +8,8 @@ _Proof-of-work generation and validation with WebGPU/WebGL for Nano cryptocurren
 
 NanoPow uses WebGPU to generate proof-of-work nonces meeting the requirements
 of the Nano cryptocurrency. WebGPU is cutting edge technology, so for browsers
-which do not yet support it, a WebGL 2.0 implementation is used as a fallback.
+which do not yet support it, WebGL 2.0 and WASM implementations are available
+as fallbacks.
 
 All calculations take place client-side, so nonces can be generated offline and
 cached for the next transaction block. For more information about the
@@ -36,12 +37,6 @@ import { NanoPow } from 'nano-pow'
 import NanoPow from 'nano-pow'
 ```
 
-A specific API can be explicitly imported:
-
-```javascript
-import { NanoPowGpu, NanoPowGl } from 'nano-pow'
-```
-
 Use it directly on a webpage with a script module:
 
 ```html
@@ -75,10 +70,12 @@ const { valid } = await NanoPow.work_validate(work, hash)
 ### Options
 ```javascript
 const options = {
+       // default best available in order: webgpu => webgl => wasm => cpu
+       api: 'webgpu',
        // default 0xFFFFFFF800000000 for send/change blocks
        difficulty: 'FFFFFFC000000000',
-       // default 8, valid range 1-32
-       effort: 16,
+       // default 4, valid range 1-32
+       effort: 8,
        // default false
        debug: true
 }
@@ -137,11 +134,11 @@ detached process, and it can also be started manually to customize behavior by
 executing the server script directly.
 
 #### Environment Variables
-`NANO_POW_PORT`: override the default port 5040
+`NANO_POW_DEBUG`: enable additional logging saved to the HOME directory
 
-`NANO_POW_EFFORT` increase or decrease demand on the GPU
+`NANO_POW_EFFORT`: increase or decrease demand on the GPU
 
-`NANO_POW_DEBUG` enable additional logging saved to the HOME directory
+`NANO_POW_PORT`: override the default port 5040
 
 ```console
 $ # Launch the server and detach from the current session