Write a Plugin
A plugin is a child directive of main gantt
directive
transcluded in Template.
-
Copy skeleton file from
docs/skeletons/plugin.js
tosrc/plugins
-
Rename the skeleton copy using the plugin name (dash-delimited notation,
plugin-name.js
) -
Open the plugin file with your favorite editor.
-
Replace
xxxxxx
with the name of the plugin (camelCase notation,pluginName
). Take special care to directive name, that must be camelCase to (ganttPluginName
). There are 5 matches. -
Register plugin in
Gruntfile.js
by adding its dash-delimited name toplugins
variable. -
Add options as binded attributes in the directive
scope
. -
Implement plugin feature using a Template Hook.
-
You can add additional files in a subfolder named as your filename (without
.js
). This folder can contains templates (*.html
), CSS (*.css
) and other JavaScript (*.js
). Those files will be included in the build.