[coldbox-3.8.1] overriding renderView()

im writing a plugin that will add js/css assets that belong to individual views.

ive overridden setView() but now need to override renderView().

is there a decorator or any other way to override that method?

just found out about the postViewRender intercept point.

might have to use that if there isnt a way to override.

Aaron,

The renderView() is part of the Renderer plugin, you could use the trick I blogged about by changing the plugin when it gets instantiated with your own version if you want too.

However, as that should become a wrapper to the original, otherwise you’re going to have to maintain that overridden code.

The best option, is to use the postViewRender and add the content you need then. Its easy portable and if you need to switch it back out for any reason, very easy to do.

very cool. so something like intercept on plugin creation, create my own that extends the original and send that back?

what is the blog link?

ultimately, using postViewRender, its going to suffice with what im doing.

http://www.andyscott.id.au/blog/a-funky-way-to-replacing-captcha-in-contentbox