mirror of
https://github.com/kbparagua/paloma
synced 2023-03-27 23:21:17 -04:00
Update README.md
This commit is contained in:
parent
17b4d8bb21
commit
0441700c08
1 changed files with 6 additions and 0 deletions
|
@ -270,6 +270,12 @@ class UsersController < ApplicationController
|
|||
end
|
||||
```
|
||||
|
||||
## Hook
|
||||
|
||||
`insert_paloma_hook` is a helper method that you can use in your views to insert Paloma's HTML hook.
|
||||
Inside this HTML hook is where the magic happens. This is the reason why Paloma can magically know what Javascript controller/action to execute. To further understand how Paloma works, you can inspect the HTML hook, by checking at the generated HTML (*inspect element*) and locate the `div` element that has the class `js-paloma-hook`.
|
||||
|
||||
Ideally, you just need to call `insert_paloma_hook` in your layouts, since the layout will always be included in every rendered view. But if you are rendering a view without a layout, make sure to call `insert_paloma_hook` in that view.
|
||||
|
||||
## Turbolinks Support
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue