Skip to content

Commit 702aa27

Browse files
authored
Simplify WebSocketLogger usage in README
Removed redundant WebSocket instantiation in example.
1 parent f7e346d commit 702aa27

1 file changed

Lines changed: 1 addition & 3 deletions

File tree

README.md

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,9 +10,7 @@ Drop-in replacement for the browser `console` API that routes all output over a
1010

1111
```typescript
1212
import { WebSocketLogger } from '@noconsole/logger';
13-
14-
const ws = new WebSocket('ws://localhost:8080');
15-
const logger = new WebSocketLogger(ws);
13+
const logger = new WebSocketLogger('ws://localhost:8080');
1614

1715
logger.log('Hello world!', { foo: 'bar' });
1816
logger.warn('High memory', { usage: '92%' });

0 commit comments

Comments
 (0)