首页
  • go 学习

    package main
    
    import (
        "fmt"
        "io/ioutil"
        "log"
        "net/http"
    
        "github.com/gin-gonic/gin"
    )
    
    // Phone asd
    type Phone interface {
        call()
    }
    
    // MiPhone asd
    type MiPhone struct {
    }
    
    阅读全文
  • go 设置代理

    go env -w GOPROXY=https://goproxy.cn,direct
    go mod init api
    go get -u github.com/gin-gonic/gin
    package main
    
    import (
        "fmt"
    
        "github.com/gin-gonic/gin"
    )
    
    func main() {
    阅读全文
  • go-gin框架基本接口

    package main
    
    import (
        "fmt"
        "github.com/gin-gonic/gin"
        "net/http"
    )
    
    type User struct {
        Name string `json:"name"`
        Age  int    `json:"age"`
    }
    
    func main() {
    
        r := gin.Default()
    
    阅读全文
  • go 学习 包的导出

    | - src
        - index.go
        - libs
            - index.go

    libs / index.go

    package libs // 属于哪个包
    //  方法名 首字母 大写才能导出
    func Count( a int, b int ) int {
        return a + b
    }
    

    index.go

    阅读全文
  • 1
Taoqun
陶群
1994-09-07
taoquns@foxmail.com
前端开发
南京

文章分类

Mac
算法
前端
python
golang
mysql
node
linux
随笔
生活
游记

我的作品

记录体重Pro(小程序)
闲蝉科技

其他推荐

webpack vue 外部css添加 postcss
nginx 常规命令操作
webpack 开启 gzip 打包 减小文件大小
SSH 免密登陆配置
python 将视频转换成音频
go 学习 hello world
gitbook 安装和使用
centos docker 安装 jenkins
开发者:Taoqun

备案/许可证编号为:皖ICP备17027395号

闲蝉科技