Skip to content

Commit a013f1a

Browse files
committed
readme example
1 parent 38c0f48 commit a013f1a

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

README.md

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,13 +22,18 @@ This module:
2222
var SecretStack = require('secret-stack')
2323
var databasePlugin = require('./some-database')
2424
var bluetoothPlugin = require('./bluetooth')
25-
var config = require('./some-config')
25+
const ssbKeys = require('ssb-keys')
26+
var keys = ssbKeys.loadOrCreateSync(path.join(__dirname, 'secret'))
27+
28+
// keys are necessary for multiserver address
29+
var config = { keys }
2630

2731
var App = SecretStack({ appKey: '1KHLiKZvAvjbY1ziZEHMXawbCEIM6qwjCDm3VYRan/s=' })
2832
.use(databasePlugin)
2933
.use(bluetoothPlugin)
3034

3135
var app = App(config)
36+
console.log('address', app.getAddress())
3237
```
3338

3439
For documentation on plugins, see [PLUGINS.md](./PLUGINS.md).

0 commit comments

Comments
 (0)