Skip to content

Commit

Permalink
feat(view): add docs for antl.switchLocale in view (adonisjs#230)
Browse files Browse the repository at this point in the history
  • Loading branch information
ntvsx193 committed Dec 13, 2017
1 parent 7e9e820 commit 65ad577
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions 04-http-lifecycle/05-views.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -151,6 +151,14 @@ If you are using the auth provider, then you can access the current logged in us
{{ auth.user }}
----

==== antl
If you are using the link:internationalization[antl provider] and you need switch locale in view, you can do it as:

[source, edge]
----
{{ antl.switchLocale('en-us') }}
----

==== csrfField
If you are using the `shield` middleware, you can access the csrfToken and field using one of the following methods.

Expand Down

0 comments on commit 65ad577

Please sign in to comment.