diff --git a/content/static/html/doc/body.tmpl b/content/static/html/doc/body.tmpl
index 6574664eb..c690fc60b 100644
--- a/content/static/html/doc/body.tmpl
+++ b/content/static/html/doc/body.tmpl
@@ -57,6 +57,28 @@
{{- end -}}
+ {{template "decls" .}}
+
+{{- end -}}
+
+{{- if .Notes -}}
+
{{"\n"}}
+
+ {{- range $marker, $content := .Notes -}}
+
+
+
{{"\n" -}}
+ {{- range $v := $content -}}
+ - {{render_doc $v.Body}}
+ {{- end -}}
+
{{"\n" -}}
+
+ {{- end -}}
+
+{{- end -}}
+ {{/* End documentation content container */}}
+
+{{- define "decls" -}}
{{"\n"}}
{{- if .Consts -}}
@@ -155,20 +177,3 @@
{{- end -}}
{{- end -}}
-
-{{- if .Notes -}}
- {{"\n"}}
-
- {{- range $marker, $content := .Notes -}}
-
-
-
{{"\n" -}}
- {{- range $v := $content -}}
- - {{render_doc $v.Body}}
- {{- end -}}
-
{{"\n" -}}
-
- {{- end -}}
-
-{{- end -}}
- {{/* End documentation content container */}}
diff --git a/internal/godoc/dochtml/testdata/deprecated.golden b/internal/godoc/dochtml/testdata/deprecated.golden
index 21dd12cf7..6899564de 100644
--- a/internal/godoc/dochtml/testdata/deprecated.golden
+++ b/internal/godoc/dochtml/testdata/deprecated.golden
@@ -96,7 +96,6 @@
-
----
-
----