Created
December 6, 2018 12:46
-
-
Save ajruckman/23f01c441446b51d688f221b88ce33a1 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html lang="en"> | |
<head> | |
<meta charset="UTF-8"> | |
<title>Demo</title> | |
<link rel="icon" href="/static/favicon.ico" type="image/x-icon"> | |
<script src="/static/script/script.js"></script> | |
<script src="/static/lib/jquery-3.3.1.min.js"></script> | |
<link href="/static/style/style.css" rel="stylesheet"> | |
</head> | |
<body> | |
{{.Demo}} | |
</body> | |
</html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package main | |
import ( | |
"fmt" | |
"github.com/gobuffalo/packr/v2" | |
) | |
func main() { | |
box := packr.New("box1", "./templates") | |
html, err := box.FindString("base.html") | |
if err != nil { | |
panic(err) | |
} | |
fmt.Println(html) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment