Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/ab70/fiber-restapi
A Fiber (Go) rest api
https://github.com/ab70/fiber-restapi
fiber golang rest-api
Last synced: about 2 months ago
JSON representation
A Fiber (Go) rest api
- Host: GitHub
- URL: https://github.com/ab70/fiber-restapi
- Owner: ab70
- Created: 2024-04-26T16:27:09.000Z (9 months ago)
- Default Branch: main
- Last Pushed: 2024-07-13T18:21:11.000Z (6 months ago)
- Last Synced: 2024-07-13T20:08:33.914Z (6 months ago)
- Topics: fiber, golang, rest-api
- Language: Go
- Homepage:
- Size: 13.7 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: readme.md
Awesome Lists containing this project
README
### Prerequisite
#### To initialize a go project there must be a go.mod file
```
go mod init github.com/ab70/fiber-restapi
```### To add a package
```
go get github.com/gofiber/fiber/v2
```### To run the project
```
go run server.go
```#### For hot reload:
```
go get -u github.com/air-verse/air#export this
export PATH=$(go env GOPATH)/bin:$PATH#reload .zshc file:
source ~/.zshrc#which air and then put that in:
nano ~/.zshrc
export PATH=$PATH:/home/ab/go/bin```
### To build for binary use this:
```
# this will generate a birany in the current directory
go build -o server server.go
```