« Back to Index

Go: Playground multiple files

View original Gist on GitHub

Tags: #go #playground

playground.go

package main

import (
	"play.ground/foo"
)

func main() {
	foo.Bar()
}

-- go.mod --
module play.ground

-- foo/foo.go --
package foo

import "fmt"

func Bar() {
	fmt.Println("The Go playground now has support for multiple files!")
}