adding filename to onHandleHTML() plugin event #175

Merged
merged 1 commit into from Feb 6, 2016

Conversation

Projects
None yet
2 participants
@skratchdot
Contributor

skratchdot commented Nov 19, 2015

I am working on a plugin, and would like to modify the html based on the file that is being generated.

I've added a simple test case, and confirmed that the fileName is being passed in the ev.data.

This commit allows me to write plugins that do things like removing the navigation on certain pages, or adding 'active' links in the header based on a regex.

It would be nice to pass this value in all plugin events, but I really want it onHandleHTML().

Docs haven't been updated.

Version has been tagged and bumped to 0.4.4.

@skratchdot

This comment has been minimized.

Show comment
Hide comment
@skratchdot

skratchdot Nov 19, 2015

Contributor

@h13i32maru - If you pull this in, can you please run npm publish so I can pull 0.4.4?

Contributor

skratchdot commented Nov 19, 2015

@h13i32maru - If you pull this in, can you please run npm publish so I can pull 0.4.4?

h13i32maru added a commit that referenced this pull request Feb 6, 2016

Merge pull request #175 from skratchdot/master
adding filename to onHandleHTML() plugin event

@h13i32maru h13i32maru merged commit 0b887a7 into esdoc:master Feb 6, 2016

@h13i32maru

This comment has been minimized.

Show comment
Hide comment
@h13i32maru

h13i32maru Feb 6, 2016

Member

Thanks for this PR! But the version number in package.json is handled by me.

Member

h13i32maru commented Feb 6, 2016

Thanks for this PR! But the version number in package.json is handled by me.

h13i32maru added a commit that referenced this pull request Feb 6, 2016

@h13i32maru

This comment has been minimized.

Show comment
Hide comment
@h13i32maru

h13i32maru Feb 6, 2016

Member

I released v0.4.4

Member

h13i32maru commented Feb 6, 2016

I released v0.4.4

@skratchdot

This comment has been minimized.

Show comment
Hide comment
@skratchdot

skratchdot Feb 6, 2016

Contributor

Thanks @h13i32maru . I'm using your tool to build these docs: http://projects.skratchdot.com/stats-collector/

I'm using onHandleHTML() to add content to the header/footer, and add links to the "extends" output:

https://github.com/skratchdot/stats-collector/blob/master/esdoc/plugin.js

but now I can do some other things based on the page a person is on. Thanks again!

Contributor

skratchdot commented Feb 6, 2016

Thanks @h13i32maru . I'm using your tool to build these docs: http://projects.skratchdot.com/stats-collector/

I'm using onHandleHTML() to add content to the header/footer, and add links to the "extends" output:

https://github.com/skratchdot/stats-collector/blob/master/esdoc/plugin.js

but now I can do some other things based on the page a person is on. Thanks again!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment