nostr-tools
Advanced tools
Comparing version 0.23.0 to 0.23.1
{ | ||
"name": "nostr-tools", | ||
"version": "0.23.0", | ||
"version": "0.23.1", | ||
"description": "Tools for making a Nostr client.", | ||
@@ -33,5 +33,13 @@ "repository": { | ||
"devDependencies": { | ||
"@esbuild-plugins/node-globals-polyfill": "^0.1.1", | ||
"esbuild": "^0.14.38", | ||
"esbuild-plugin-alias": "^0.2.1", | ||
"eslint": "^8.5.0", | ||
"eslint-plugin-babel": "^5.3.1" | ||
"eslint-plugin-babel": "^5.3.1", | ||
"events": "^3.3.0", | ||
"readable-stream": "^3.6.0" | ||
}, | ||
"scripts": { | ||
"prepublish": "node build.js" | ||
} | ||
} |
@@ -73,1 +73,18 @@ # nostr-tools | ||
For other utils please read the source (for now). | ||
### Using from the browser (if you don't want to use a bundler) | ||
You can import nostr-tools as an ES module. Just add a script tag like this: | ||
```html | ||
<script type="module"> | ||
import {generatePrivateKey} from 'https://unpkg.com/nostr-tools/nostr.js' | ||
console.log(generatePrivateKey()) | ||
</script> | ||
``` | ||
And import whatever function you would import from `"nostr-tools"` in a bundler. | ||
## License | ||
Public domain. |
23890
14
696
90
7