5

Possible Duplicate:
Design Patterns used in the jQuery library

jquery is based on which javascript design pattern ? And what design pattern to follow when writing jquery plugins ? Also what design pattern is generally used when writing OO javascript ?

Community
  • 1
  • 1
ktm
  • 6,025
  • 24
  • 69
  • 95

2 Answers2

2

I think answer for your question is

Design Patterns used in the jQuery library

Useful links for plugin development:

A Plugin Development Pattern and jQuery Plugin Design Patterns

Community
  • 1
  • 1
gandil
  • 5,398
  • 5
  • 24
  • 46
  • 1
    Don't answer by linking to another question. Comment instead and vote to close if you can. *Edit: This was before the other links have been added.* – Felix Kling May 22 '11 at 00:03
  • 1
    Ok Felix. Good to know. But also i added some other links. I will do as you say. Thanks for warning. – gandil May 22 '11 at 00:07
0

jQuery is based on the Module Pattern. You "can" write your module in the same manner. However, there are options.

You can write AMD-style using the CommonJS specification. Here is more information on it.

Community
  • 1
  • 1
Prisoner ZERO
  • 13,848
  • 21
  • 92
  • 137