1
0
mirror of https://github.com/labstack/echo.git synced 2024-12-24 20:14:31 +02:00

updated website

Signed-off-by: Vishal Rana <vr@labstack.com>
This commit is contained in:
Vishal Rana 2016-11-20 14:16:22 -08:00
parent 5a3fe3f423
commit 054a310e70
57 changed files with 133 additions and 123 deletions

View File

@ -1,2 +1,2 @@
build:
rm -rf public/v3 && hugo
rm -rf public && hugo

View File

@ -4,39 +4,11 @@
"title": "Echo - Fast and unfancy HTTP server framework for Go (Golang)",
"canonifyurls": true,
"googleAnalytics": "UA-85059636-2",
"publishdir": "public/v3",
"permalinks": {
"guide": "/guide/:filename",
"middleware": "/middleware/:filename",
"recipes": "/recipes/:filename"
},
"menu": {
"side": [{
"name": "Guide",
"pre": "<i class='fa fa-book'></i>",
"weight": 1,
"identifier": "guide",
"url": "guide"
},{
"name": "Middleware",
"pre": "<i class='fa fa-filter'></i>",
"weight": 1,
"identifier": "middleware",
"url": "middleware"
}, {
"name": "Recipes",
"pre": "<i class='fa fa-code'></i>",
"weight": 2,
"identifier": "recipes",
"url": "recipes"
}, {
"name": "Godoc",
"pre": "<i class='fa fa-file-text-o'></i>",
"weight": 3,
"identifier": "godoc",
"url": "godoc"
}]
},
"params": {
"image": "https://echo.labstack.com/images/logo.png",
"description": "Echo is a high performance, extensible, minimalist web framework for Go (Golang)."

11
website/content/godoc.md Normal file
View File

@ -0,0 +1,11 @@
+++
title = "Godoc"
description = "Godoc"
type = "godoc"
[menu.main]
name = "Godoc"
pre = "<i class='fa fa-file-text-o'></i>"
weight = 3
identifier = "godoc"
url = "/godoc"
+++

View File

@ -1,6 +1,6 @@
+++
title = "echo"
[menu.side]
[menu.main]
name = "echo"
parent = "godoc"
weight = 1

View File

@ -1,6 +1,6 @@
+++
title = "middleware"
[menu.side]
[menu.main]
name = "middleware"
identifier = "godoc-middleware"
parent = "godoc"

View File

@ -2,6 +2,12 @@
title = "Guide"
description = "Guide"
type = "guide"
[menu.main]
name = "Guide"
pre = "<i class='fa fa-book'></i>"
weight = 1
identifier = "guide"
url = "/guide"
+++
## Quick Start

View File

@ -1,7 +1,7 @@
+++
title = "Context"
description = "Context in Echo"
[menu.side]
[menu.main]
name = "Context"
identifier = "context"
parent = "guide"

View File

@ -1,7 +1,7 @@
+++
title = "Cookies"
description = "Handling cookie in Echo"
[menu.side]
[menu.main]
name = "Cookies"
parent = "guide"
weight = 6

View File

@ -1,7 +1,7 @@
+++
title = "Customization"
description = "Customizing Echo"
[menu.side]
[menu.main]
name = "Customization"
parent = "guide"
weight = 3

View File

@ -1,7 +1,7 @@
+++
title = "Error Handling"
description = "Error handling in Echo"
[menu.side]
[menu.main]
name = "Error Handling"
parent = "guide"
weight = 8

View File

@ -1,7 +1,7 @@
+++
title = "FAQ"
description = "Frequently asked questions in Echo"
[menu.side]
[menu.main]
name = "FAQ"
parent = "guide"
weight = 20

View File

@ -1,7 +1,7 @@
+++
title = "Installation"
description = "Installing Echo"
[menu.side]
[menu.main]
name = "Installation"
parent = "guide"
weight = 1
@ -15,7 +15,7 @@ $ go get -u github.com/labstack/echo
> Ideally you should rely on a [package manager](https://github.com/avelino/awesome-go#package-management) like glide or govendor to use a specific [version](https://github.com/labstack/echo/releases) of Echo.
### [Migrating Guide](/guide/migration)
## [Migrating Guide](/guide/migration)
Echo follows [semantic versioning](http://semver.org) managed through GitHub releases.
Specific version of Echo can be installed using a [package manager](https://github.com/avelino/awesome-go#package-management).

View File

@ -1,7 +1,7 @@
+++
title = "Migration"
description = "Migration"
[menu.side]
[menu.main]
name = "Migration"
parent = "guide"
weight = 2

View File

@ -1,7 +1,7 @@
+++
title = "Request"
description = "Handling HTTP request in Echo"
[menu.side]
[menu.main]
name = "Request"
parent = "guide"
weight = 6

View File

@ -1,7 +1,7 @@
+++
title = "Routing"
description = "Routing HTTP request in Echo"
[menu.side]
[menu.main]
name = "Routing"
parent = "guide"
weight = 4

View File

@ -1,7 +1,7 @@
+++
title = "Static Files"
description = "Serving static files in Echo"
[menu.side]
[menu.main]
name = "Static Files"
parent = "guide"
weight = 3

View File

@ -1,7 +1,7 @@
+++
title = "Templates"
description = "How to use templates in Echo"
[menu.side]
[menu.main]
name = "Templates"
parent = "guide"
weight = 3

View File

@ -1,7 +1,7 @@
+++
title = "Testing"
description = "Testing handler and middleware in Echo"
[menu.side]
[menu.main]
name = "Testing"
parent = "guide"
weight = 9

View File

@ -2,6 +2,12 @@
title = "Middleware"
description = "Middleware"
type = "middleware"
[menu.main]
name = "Middleware"
pre = "<i class='fa fa-filter'></i>"
weight = 2
identifier = "middleware"
url = "/middleware"
+++
## Overview

View File

@ -1,7 +1,7 @@
+++
title = "BasicAuth Middleware"
description = "Basic auth middleware for Echo"
[menu.side]
[menu.main]
name = "BasicAuth"
parent = "middleware"
weight = 5

View File

@ -1,7 +1,7 @@
+++
title = "BodyLimit Middleware"
description = "Body limit middleware for Echo"
[menu.side]
[menu.main]
name = "BodyLimit"
parent = "middleware"
weight = 5

View File

@ -1,7 +1,7 @@
+++
title = "CORS Middleware"
description = "CORS middleware for Echo"
[menu.side]
[menu.main]
name = "CORS"
parent = "middleware"
weight = 5

View File

@ -1,7 +1,7 @@
+++
title = "CSRF Middleware"
description = "CSRF middleware for Echo"
[menu.side]
[menu.main]
name = "CSRF"
parent = "middleware"
weight = 5

View File

@ -1,7 +1,7 @@
+++
title = "Gzip Middleware"
description = "Gzip middleware for Echo"
[menu.side]
[menu.main]
name = "Gzip"
parent = "middleware"
weight = 5

View File

@ -1,7 +1,7 @@
+++
title = "JWT Middleware"
description = "JWT middleware for Echo"
[menu.side]
[menu.main]
name = "JWT"
parent = "middleware"
weight = 5

View File

@ -1,7 +1,7 @@
+++
title = "Logger Middleware"
description = "Logger middleware for Echo"
[menu.side]
[menu.main]
name = "Logger"
parent = "middleware"
weight = 5

View File

@ -1,7 +1,7 @@
+++
title = "MethodOverride Middleware"
description = "Method override middleware for Echo"
[menu.side]
[menu.main]
name = "MethodOverride"
parent = "middleware"
weight = 5

View File

@ -1,7 +1,7 @@
+++
title = "Recover Middleware"
description = "Recover middleware for Echo"
[menu.side]
[menu.main]
name = "Recover"
parent = "middleware"
weight = 5

View File

@ -1,7 +1,7 @@
+++
title = "Redirect Middleware"
description = "Redirect middleware for Echo"
[menu.side]
[menu.main]
name = "Redirect"
parent = "middleware"
weight = 5

View File

@ -1,7 +1,7 @@
+++
title = "Secure Middleware"
description = "Secure middleware for Echo"
[menu.side]
[menu.main]
name = "Secure"
parent = "middleware"
weight = 5

View File

@ -1,7 +1,7 @@
+++
title = "TrailingSlash Middleware"
description = "Trailing slash middleware for Echo"
[menu.side]
[menu.main]
name = "TrailingSlash"
parent = "middleware"
weight = 5

View File

@ -2,6 +2,12 @@
title = "Recipes"
description = "Recipes"
type = "recipes"
[menu.main]
name = "Recipes"
pre = "<i class='fa fa-code'></i>"
weight = 2
identifier = "recipes"
url = "/recipes"
+++
## Echo Examples

View File

@ -1,7 +1,7 @@
+++
title = "CORS Example"
description = "CORS example for Echo"
[menu.side]
[menu.main]
name = "CORS"
identifier = "cors-middleware"
parent = "recipes"

View File

@ -1,7 +1,7 @@
+++
title = "CRUD Example"
description = "CRUD (Create, read, update and delete) example for Echo"
[menu.side]
[menu.main]
name = "CRUD"
parent = "recipes"
weight = 2

View File

@ -1,7 +1,7 @@
+++
title = "Embed Resources Example"
description = "Embed resources example for Echo"
[menu.side]
[menu.main]
name = "Embed Resources"
parent = "recipes"
weight = 14

View File

@ -1,7 +1,7 @@
+++
title = "File Upload Example"
description = "File upload example for Echo"
[menu.side]
[menu.main]
name = "File Upload"
parent = "recipes"
weight = 7

View File

@ -1,7 +1,7 @@
+++
title = "Google App Engine Example"
description = "Google App Engine example for Echo"
[menu.side]
[menu.main]
name = "Google App Engine"
parent = "recipes"
weight = 12

View File

@ -1,7 +1,7 @@
+++
title = "Graceful Shutdown Example"
description = "Graceful shutdown example for Echo"
[menu.side]
[menu.main]
name = "Graceful Shutdown"
parent = "recipes"
weight = 13

View File

@ -1,7 +1,7 @@
+++
title = "Hello World Example"
description = "Hello world example for Echo"
[menu.side]
[menu.main]
name = "Hello World"
parent = "recipes"
weight = 1

View File

@ -1,7 +1,7 @@
+++
title = "HTTP/2 Example"
description = "HTTP/2 example for Echo"
[menu.side]
[menu.main]
name = "HTTP/2"
parent = "recipes"
weight = 3

View File

@ -1,7 +1,7 @@
+++
title = "JSONP Example"
description = "JSONP example for Echo"
[menu.side]
[menu.main]
name = "JSONP"
parent = "recipes"
weight = 6

View File

@ -1,7 +1,7 @@
+++
title = "JWT Example"
description = "JWT example for Echo"
[menu.side]
[menu.main]
name = "JWT"
identifier = "jwt-recipe"
parent = "recipes"

View File

@ -1,7 +1,7 @@
+++
title = "Middleware Example"
description = "Middleware example for Echo"
[menu.side]
[menu.main]
name = "Middleware"
parent = "recipes"
weight = 3

View File

@ -1,7 +1,7 @@
+++
title = "Streaming Response Example"
description = "Streaming response example for Echo"
[menu.side]
[menu.main]
name = "Streaming Response"
parent = "recipes"
weight = 3

View File

@ -1,7 +1,7 @@
+++
title = "Subdomains Example"
description = "Subdomains example for Echo"
[menu.side]
[menu.main]
name = "Subdomains"
parent = "recipes"
weight = 10

View File

@ -1,7 +1,7 @@
+++
title = "WebSocket Example"
description = "WebSocket example for Echo"
[menu.side]
[menu.main]
name = "WebSocket"
parent = "recipes"
weight = 5

View File

@ -1,6 +1,7 @@
+++
title = "Support Echo"
description = "Support Echo"
type = "single"
+++
<p>

View File

@ -1,9 +1,8 @@
{{ partial "head.html" . }}
<body>
{{ partial "navbar.html" . }}
{{ partial "topnav.html" . }}
{{ partial "sidenav.html" . }}
{{ partial "search.html" . }}
<div class="w3-main w3-padding-64">
<div class="w3-main w3-padding-64">
{{ partial "ad.html" }}
<div class="w3-row-padding">
<div class="w3-col m9 l9">
@ -14,7 +13,7 @@
{{ .Content }}
</section>
<footer>
<div class="w3-panel w3-pale-yellow w3-leftbar w3-border-yellow">
<div class="w3-panel w3-pale-blue w3-leftbar w3-border-blue">
<p>
<i class="fa fa-pencil" aria-hidden="true"></i>
<a href="https://github.com/labstack/echo/blob/master/website/content/{{ .File.Path }}">

View File

@ -1,8 +1,10 @@
{{ partial "head.html" . }}
<body>
{{ partial "navbar.html" . }}
{{ partial "search.html" . }}
<div class="w3-content w3-padding-64">
{{ partial "topnav.html" . }}
<div class="w3-hide-large">
{{ partial "sidenav.html" . }}
</div>
<div class="w3-container w3-content w3-padding-64">
{{ partial "ad.html" }}
<div class="w3-row-padding">
<div class="w3-col m9 l9">

View File

@ -20,16 +20,13 @@
</a>
</p>
</footer>
<script type="text/javascript" src="//cdn.jsdelivr.net/docsearch.js/1/docsearch.min.js"></script>
<script type="text/javascript" src="https://cdn.jsdelivr.net/docsearch.js/2/docsearch.min.js"></script>
<script type="text/javascript">
docsearch({
apiKey: '69dfc65b57ccba29ec34b68aa5b274ed',
indexName: 'labstack',
inputSelector: '#search-box',
autocompleteOptions: {
dropdownMenuContainer: '#search-menu'
}
});
docsearch({
apiKey: '69dfc65b57ccba29ec34b68aa5b274ed',
indexName: 'labstack',
inputSelector: '#search-box'
});
</script>
<script src="https://cdn.labstack.com/scripts/prism.js"></script>
<script src="https://cdn.labstack.com/scripts/doc.js"></script>

View File

@ -19,7 +19,7 @@
{{ if ne .URL "/" }}{{ .Title }} | {{ end }}{{ .Site.Title }}
</title>
<link rel="stylesheet" href="https://unpkg.com/font-awesome@4.6.3/css/font-awesome.min.css">
<link rel="stylesheet" href="https://cdn.jsdelivr.net/docsearch.js/1/docsearch.min.css">
<link rel="stylesheet" href="https://cdn.jsdelivr.net/docsearch.js/2/docsearch.min.css">
<link rel="stylesheet" href="https://cdn.labstack.com/styles/w3.css">
<link rel="stylesheet" href="https://cdn.labstack.com/styles/prism.css">
<link rel="stylesheet" href="https://cdn.labstack.com/styles/base.css">

View File

@ -1,14 +0,0 @@
<nav class="navbar">
<a href="/"><img class="logo" src="/images/logo.png" alt="Echo"></a>
<span class="w3-hide-small w3-hide-medium">
<input id="search-box" type="text" class="w3-input" placeholder="Search...">
<i class="fa fa-search"></i>
</span>
<span class="links">
<a href="/guide">Guide</a>
<a href="/middleware">Middleware</a>
<a href="/recipes">Recipes</a>
</ul>
</span>
<span class="w3-xxlarge w3-hide-large" onclick="openSidenav()">&#9776;</span>
</nav>

View File

@ -1 +0,0 @@
<div id="search-menu"></div>

View File

@ -2,23 +2,27 @@
<span class="w3-closenav w3-xxlarge w3-hide-large" onclick="closeSidenav()">
&times;
</span>
<a class="support w3-btn w3-white w3-border w3-border-theme w3-round-xlarge" href="/support-echo">
<a class="w3-btn w3-white w3-border w3-border-theme w3-round-xlarge support-us" href="/support-echo">
<i class="fa fa-heart" aria-hidden="true"></i> Support Echo
</a>
{{ $currentNode := . }}
{{ range where .Site.Menus.side "Identifier" .Type }}
<h3>{{ .Pre }} {{ .Name }}</h3>
{{ range .Children }}
<a{{ if $currentNode.IsMenuCurrent "side" . }} class="active"{{ end }} href="{{ .URL }}">
{{ .Name }}
</a>
{{ if .HasChildren }}
{{ range .Children }}
<a {{ if $currentNode.IsMenuCurrent "side" . }} class="active"{{ end }} href="{{ .URL }}">
{{ .Name }}
</a>
{{ end }}
<div class="w3-hide-large menu">
{{ range .Site.Menus.main }}
<a{{ if or ($currentNode.HasMenuCurrent "main" .) ($currentNode.IsMenuCurrent "main" .) }} class="active"{{ end }} href="{{ .URL }}">
<div class="w3-xlarge w3-padding-top">{{ .Name }}</div>
</a>
{{ end }}
</div>
<div class="sub-menu">
{{ if .IsPage }}
{{ range where .Site.Menus.main "Identifier" .Type }}
<div class="w3-xlarge w3-padding-top">{{ .Pre }} {{ .Name }}</div>
{{ range .Children }}
<a{{ if $currentNode.IsMenuCurrent "main" . }} class="active"{{ end }} href="{{ .URL }}">
{{ .Name }}
</a>
{{ end }}
{{ end }}
{{ end }}
</div>
</nav>

View File

@ -0,0 +1,14 @@
<nav class="topnav">
<a href="/"><img class="logo" src="/images/logo.png" alt="Echo"></a>
<span class="w3-hide-small">
<input id="search-box" type="text" class="w3-input" placeholder="Search...">
<i class="fa fa-search"></i>
</span>
<span class="w3-hide-small w3-hide-medium menu">
{{ $currentNode := . }}
{{ range .Site.Menus.main }}
<a{{ if or ($currentNode.HasMenuCurrent "main" .) ($currentNode.IsMenuCurrent "main" .) }} class="active"{{ end }} href="{{ .URL }}">{{ .Name }}</a>
{{ end }}
</span>
<span class="w3-xxlarge w3-hide-large" onclick="openSidenav()">&#9776;</span>
</nav>

View File

@ -0,0 +1,14 @@
{{ partial "head.html" . }}
<body>
{{ partial "topnav.html" . }}
<div class="w3-container w3-content w3-padding-64">
<div class="w3-row-padding">
<div class="w3-col m9 l9">
<h1>{{ .Title }}</h1>
{{ .Content }}
</div>
</div>
</div>
{{ partial "footer.html" . }}
</body>
</html>

View File

@ -1,8 +1 @@
.navbar .links a {
text-decoration: none;
color: inherit;
margin-left: 12px;
}
.navbar .links a:hover {
border-bottom: 4px solid #00AFD1;
}