Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/gustavohenrique/grpc-web-golang-vuejs
gRPC-Web with Go and VueJS (Quasar Framework)
https://github.com/gustavohenrique/grpc-web-golang-vuejs
Last synced: about 1 month ago
JSON representation
gRPC-Web with Go and VueJS (Quasar Framework)
- Host: GitHub
- URL: https://github.com/gustavohenrique/grpc-web-golang-vuejs
- Owner: gustavohenrique
- Created: 2020-02-10T02:26:15.000Z (almost 5 years ago)
- Default Branch: master
- Last Pushed: 2023-03-06T23:31:08.000Z (almost 2 years ago)
- Last Synced: 2024-04-16T03:18:23.432Z (9 months ago)
- Language: Go
- Size: 2.8 MB
- Stars: 66
- Watchers: 3
- Forks: 16
- Open Issues: 8
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# grpc-web-golang-vuejs
> An example using gRPC-Web with Go and VueJS (Quasar Framework)
The post about this code can be found in my personal blog [gustavohenrique.net](https://gustavohenrique.net).
## Setup
1. Install the latest release of Protocol Buffers from [here](https://github.com/protocolbuffers/protobuf/releases/latest).
2. Install the Go protocol buffers plugin running `go get -u github.com/golang/protobuf/protoc-gen-go`.
3. Install the *protoc-gen-grpc-web* protoc plugin from [here](https://github.com/grpc/grpc-web/releases).## Running
### Compile the protobuf definitions
```sh
protoc -I proto proto/*.proto --proto_path=./proto --go_out=plugins=grpc:./backend/proto
protoc -I proto proto/*.proto --js_out=import_style=commonjs:./frontend/proto --grpc-web_out=import_style=commonjs,mode=grpcwebtext:./frontend/proto
```### Backend
Open a terminal session and run:
```sh
cd backend
go run main.go
```The backend server will create an in memory SQLite database.
### Frontend
Open another terminal session:
```sh
cd frontend
npm i -g @quasar/cli
npm i
quasar dev
```## License
MIT