What is the best way to create parametrized "components" in Node.js?

The initial question

My question can be easily misunderstood, so I will use an example, or better, I will make a comparison.

Consider ASP.NET web applications. There it is possible to define ascx components. Those components are quite nice because they define pieces of reusable code with some more intelligent features that make them not just pieces of plain code... but parametrized parts for a web application.

My question is, of course considering that Node.js is not ASP.NET: what is the most similar solution in Node.js to define reusable components (parametrized)?

Thankyou

For those not familiar with ASP.NET

I am aware that not everyone might be familiar with ASP.NET. So I am going to detail a little bit more what I need here. Passing parameters to an html or jade segmente of code is something I can do in Node.js, but what I would like to do is writing my jade/html code into a file (it contains some divs and something else), and then reference it inside another jade/html document or one parameter passed inside it.

The new revised question

When I was told to use mixins in order to solve this issue, I started looking for them and also tried some, it was ok, I managed getting the simplest mixins done, but when I had to make things a little more complex, mixins started behaving strangely. So now I am wondering about whether they are the solution I have been looking for. So now I am going to explain in details what I want to achieve (as I was too generic).

I have a web page written using Jade and I need to create a component that I can reuse throughout my page. This component is just a structured div that will contain an article. If I were to write this component in pseudo-code, this is what it would probably look like in Jadeish syntax:

component article(@title, @subtitle, @articlebody, @writtenon)
.article
  .head {@title}
  .head {@subtitle}
  div(style='float:left;clear:both')
    .body
      {@articlecontent}
    .foot
      {@writtenon}

So, as you can see, I want this bunch of code to be parametrized so I can reuse it like this in my page:

doctype 5
html
  head
    title = title
  body
    .article('my first art', 'dummy subtitle', 'bla bla bla... lorem ipsum', '12/12/2012')
    .article('my second art', 'dummy subtitle', 'bla bla bla... lorem ipsum', '12/12/2012')

and so on...

Consider also that parameters might be long values. In my example, one of the parameters is the body of an article. I need to insert there the html code of the body

I searched the web in order to understand how to do this, but could not find any tutorial or valid example.

Can you help me please? Thankyou

I am unfamiliar with ascx files so I don't know if this is what you are thinking of, but there are different template engines that have been written for node.js that allow for reuse of frontend templates (html-like files). For example, in the Jade engine has mixins that allow you to pass parameters to a template.