RE: [coldbox:3843] Re: Passing parameters to a viewlet

We just had this discussion about a month ago. :slight_smile: Read it here:

http://groups.google.com/group/coldbox/browse_thread/thread/4582bce260353168#

The OP ended up using the rc, and placing a specially named struct in it
for the vars that each view used to allow flexibility without variable
name collisions.

Dorioo had some good suggestions in the thread as well about
encapsulating your viewlets in a service call to explicitly pass in your
arguments.

~Brad

A friend shared a custom tag that handles this for me. I store my variables in the request collection and use a custom tag to extract the necessary values into the variables scope of the view. This keeps the view unaware of the framework and also documents its dependencies. If you’re new to Coldbox, you’ll soon learn that there are many ways to skin a cat. :slight_smile: