Skip to content

Commit e47a070

Browse files
committed
Doc typos fix #1385
1 parent c04e5e1 commit e47a070

5 files changed

Lines changed: 14 additions & 14 deletions

File tree

docs/asciidoc/body.adoc

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,7 @@ and returns a single result of the given type.
9090
{
9191
val lib = FavoriteJson() // <1>
9292
93-
decoder(MediaType.json, { ctx, type -> // <2>
93+
decoder(MediaType.json) { ctx, type -> // <2>
9494
9595
val body = ctx.body().bytes() // <3>
9696
@@ -105,7 +105,7 @@ and returns a single result of the given type.
105105

106106
<1> Choose your favorite `json` library
107107
<2> Check if the `Content-Type` header matches `application/json`
108-
<3> Ready the body as `byte[]`
108+
<3> Read the body as `byte[]`
109109
<4> Parse the `body` and use the requested type
110110
<5> Route handler now call the `body(Type)` function to trigger the decoder function
111111

@@ -203,7 +203,7 @@ produces a result.
203203
{
204204
val lib = FavoriteJson() // <1>
205205
206-
encoder(MediaType.json, { ctx, result -> // <2>
206+
encoder(MediaType.json) { ctx, result -> // <2>
207207
208208
val json = lib.toJson(result) // <3>
209209

docs/asciidoc/routing.adoc

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -672,7 +672,7 @@ Route pipeline (a.k.a route stack) is a composition of one or more decorator(s)
672672
Output:
673673

674674
<1> `/1` => `3`
675-
<2> `/2` => `5`
675+
<2> `/2` => `4`
676676

677677
Behind the scene, Jooby builds something like:
678678

@@ -833,7 +833,7 @@ A `scoped decorator` looks like:
833833
}
834834
835835
get("/4") { 4 } // <2>
836-
});
836+
}
837837
838838
get("/3") { 3 } // <3>
839839
}
@@ -971,7 +971,7 @@ class Bar: Kooby({
971971
972972
})
973973
974-
class Bar: Kooby({
974+
class App: Kooby({
975975
use(Foo()) // <1>
976976
977977
use(Bar()) // <2>

docs/asciidoc/static-files.adoc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -127,7 +127,7 @@ SPAs mode never generates a `NOT FOUND (404)` response, unresolved assets fallba
127127

128128
=== Options
129129

130-
The javadoc:AssetHandler[] automatically handles `E-Tag` and `Las-Modified` headers. You can turn
130+
The javadoc:AssetHandler[] automatically handles `E-Tag` and `Last-Modified` headers. You can turn
131131
control these headers programmatically:
132132

133133
.Asset handler options:

docs/asciidoc/templates.adoc

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ Templates are available via javadoc:ModelAndView[] and requires a javadoc:Templa
1010
1111
get("/", ctx -> {
1212
Map<String, Object> model = ...; <2>
13-
return new ModelAndModel("index.html", model); <3>
13+
return new ModelAndView("index.html", model); <3>
1414
});
1515
}
1616
----
@@ -23,7 +23,7 @@ Templates are available via javadoc:ModelAndView[] and requires a javadoc:Templa
2323
2424
get("/") { ctx ->
2525
val model = mapOf(...) <2>
26-
ModelAndModel("index.html", model) <3>
26+
ModelAndView("index.html", model) <3>
2727
}
2828
}
2929
----
@@ -54,11 +54,11 @@ The file extension allow us to use/mix multiple template engines too:
5454
install(new FreemarkerModule()); <2>
5555
5656
get("/first", ctx -> {
57-
return new ModelAndModel("index.hbs", model); <3>
57+
return new ModelAndView("index.hbs", model); <3>
5858
});
5959
6060
get("/second", ctx -> {
61-
return new ModelAndModel("index.ftl", model); <4>
61+
return new ModelAndView("index.ftl", model); <4>
6262
});
6363
}
6464
----
@@ -71,11 +71,11 @@ The file extension allow us to use/mix multiple template engines too:
7171
install(FreemarkerModule()) <2>
7272
7373
get("/first") { ctx ->
74-
ModelAndModel("index.hbs", model) <3>
74+
ModelAndView("index.hbs", model) <3>
7575
}
7676
7777
get("/second") { ctx ->
78-
ModelAndModel("index.ftl", model) <4>
78+
ModelAndView("index.ftl", model) <4>
7979
}
8080
}
8181
----

docs/asciidoc/value-api.adoc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ The `value()` family methods always retrieve a `value`. If there is no value, a
8080
Default and optional value are available in two different ways:
8181

8282
- Providing a default value
83-
- Requesting an `java.uti.Optional` object
83+
- Requesting an `java.util.Optional` object
8484

8585
.Java
8686
[source, java,role="primary"]

0 commit comments

Comments
 (0)