Skip to main content
Search type Search syntax
Tags [tag]
Exact "words here"
Author user:1234
user:me (yours)
Score score:3 (3+)
score:0 (none)
Answers answers:3 (3+)
answers:0 (none)
isaccepted:yes
hasaccepted:no
inquestion:1234
Views views:250
Code code:"if (foo != bar)"
Sections title:apples
body:"apples oranges"
URL url:"*.example.com"
Saves in:saves
Status closed:yes
duplicate:no
migrated:no
wiki:no
Types is:question
is:answer
Exclude -[tag]
-apples
For more details on advanced search visit our help page
Results tagged with
Search options answers only not deleted user 14625

This pattern is like the module pattern; it focuses on public & private methods. The difference is that the revealing module pattern was engineered as a way to ensure that all methods and variables are kept private until they are explicitly exposed; usually through an object literal returned by the closure in which it’s defined. It also allows the developer to avoid a lot of `this.` in the code.

2 votes
Accepted

Clipboard support in jQuery using revealing module pattern

Interesting question, your code is very readable. However, if you only reveal an init function, then really there is not much sense in using a revealing pattern. I would probably not self execute st …
Jamal's user avatar
  • 34.9k
4 votes
Accepted

First "Revealing Module" implementation

I like your code, good use of the Revealing Module pattern. I only have the following minor observations: mtype could use a better name ( I know, jqGrid uses it ) autowidth -> autoWidth ( lowerCame …
Peter's user avatar
  • 145
1 vote

Countdown module that hides an element when a specified date is reached

My notes: There is no need to create a function that calls check, you can just pass check There is no need for function hide, you only call it once, and it only has 1 line of code, I would inline th …
konijn's user avatar
  • 33.8k
5 votes
Accepted

Rock-Paper-Scissors with the revealing module pattern

I like your question, I think if you are going to export one function, and then immediately execute it, then you are better served with a self executing query. You are writing a game, I would use a …
konijn's user avatar
  • 33.8k
1 vote

Singleton model for modifying future .chart elements

I think you are overdoing the underscores, you will find that conflicts will be rare. Furthermore, I can understand that you want to centralize the iteration over the chart elements, but why would yo …
konijn's user avatar
  • 33.8k