https://github.com/rolandjitsu/streams-api
A simple example of how to use the web streams API.
https://github.com/rolandjitsu/streams-api
golang javascript react streams streams-api
Last synced: 10 months ago
JSON representation
A simple example of how to use the web streams API.
- Host: GitHub
- URL: https://github.com/rolandjitsu/streams-api
- Owner: rolandjitsu
- License: mit
- Created: 2020-11-08T05:48:14.000Z (about 5 years ago)
- Default Branch: master
- Last Pushed: 2020-11-22T08:31:55.000Z (about 5 years ago)
- Last Synced: 2025-03-01T06:28:46.940Z (10 months ago)
- Topics: golang, javascript, react, streams, streams-api
- Language: Go
- Homepage: https://rolandsdev.blog/the-streams-api
- Size: 227 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Streams API
> A simple example of using the [Streams API](https://developer.mozilla.org/en-US/docs/Web/API/Streams_API).
[](https://github.com/rolandjitsu/streams-api/actions?query=workflow%3ATest)
## Client
The app was bootstrapped with [Create React App](https://github.com/facebook/create-react-app).
To start the app server run:
```bash
yarn start
```
The above runs the app in the development mode. Open [http://localhost:3000](http://localhost:3000) to view it in the browser.
To start the tests in interactive mode run:
```bash
yarn test
```
## Server
To run the server run:
```bash
go run ./main.go
```
To run tests run:
```bash
go test .
```
To avoid caching during tests use:
```bash
go test -count=1 .
```
To run benchmark tests use the `-bench` flag:
```bash
go test -bench=. .
```
To get coverage reports use the `-cover` flag:
```bash
go test -coverprofile=coverage.out .
```
And to view the profile run:
```bash
go tool cover -html=coverage.out
```