diff --git a/tutos/7.1/manual/basics.wiki b/tutos/7.1/manual/basics.wiki index 851f4477..8b9d0233 100644 --- a/tutos/7.1/manual/basics.wiki +++ b/tutos/7.1/manual/basics.wiki @@ -509,7 +509,7 @@ This greatly simplifies communication between server and client. Pages can be generated either on the server or the client. The first HTTP request usually returns a server-side generated HTML page -(thus indexable by search engines), but subsequent page generations are done +(thus indexable by search engines), but subsequent page generations can be done by the client for better performance. In a mobile app, all pages are usually generated on the client. @@ -547,7 +547,7 @@ Example: button ~a:[a_onclick [%client fun ev -> ... ]] [ ... ] >> -The syntax is {{{[%client ( : ) }}}. +The syntax is {{{[%client ( : )]}}}. Type annotation is almost always required. These client fragments can be manipulated as server side OCaml values: @@ -562,7 +562,7 @@ If such section is reached while generating a page on client side, the client-side code will be executed immediately (In that case, you can delay the execution, if needed, for example with function -<>). +<> to wait for the element to be actually displayed). If such section is reached during module initialization on the server (global client section), it will be executed on client side everytime @@ -618,7 +618,8 @@ server-side program and also inserted in the generated page. ===Example=== This section shows a typical example of client-server code: call a function -when user clicks on a page element. +when user clicks on a page element. Take time to analyse this example, +as most of your code will probably be very similar. < ... ]] [ ... ] >> -The syntax is {{{[%client ( : ) }}}. +The syntax is {{{[%client ( : )]}}}. Type annotation is almost always required. These client fragments can be manipulated as server side OCaml values: @@ -562,7 +562,7 @@ If such section is reached while generating a page on client side, the client-side code will be executed immediately (In that case, you can delay the execution, if needed, for example with function -<>). +<> to wait for the element to be actually displayed). If such section is reached during module initialization on the server (global client section), it will be executed on client side everytime @@ -618,7 +618,8 @@ server-side program and also inserted in the generated page. ===Example=== This section shows a typical example of client-server code: call a function -when user clicks on a page element. +when user clicks on a page element. Take time to analyse this example, +as most of your code will probably be very similar. <