Changes
Page history
Update custom plugins
authored
Nov 27, 2017
by
Thimo Kraemer
Hide whitespace changes
Inline
Side-by-side
custom-plugins.md
View page @
43782383
...
@@ -19,9 +19,9 @@ An action is a Javascript function that is called when the action
...
@@ -19,9 +19,9 @@ An action is a Javascript function that is called when the action
is executed. It receives the node and a parameter object::
is executed. It receives the node and a parameter object::
```
js
```
js
kss
.
registerActionProvider
(
'
replaceInnerHTML
'
,
function
(
node
,
params
)
{
kss
.
registerActionProvider
(
'
replaceInnerHTML
'
,
function
(
node
,
params
)
{
node
.
innerHTML
=
params
.
html
;
node
.
innerHTML
=
params
.
html
;
});
});
```
```
Creating a parameter provider
Creating a parameter provider
...
@@ -31,9 +31,9 @@ A parameter provider is a Javascript function that is called for each
...
@@ -31,9 +31,9 @@ A parameter provider is a Javascript function that is called for each
parameter for an action. It receives the node and all arguments::
parameter for an action. It receives the node and all arguments::
```
js
```
js
kss
.
registerParameterProvider
(
'
nodeAttr
'
,
function
(
node
,
name
)
{
kss
.
registerParameterProvider
(
'
nodeAttr
'
,
function
(
node
,
name
)
{
return
node
.
getAttribute
(
name
);
return
node
.
getAttribute
(
name
);
});
});
```
```
Creating a custom event binder
Creating a custom event binder
...
...
...
...