Profile
Achievement
coprolit's Recent Snippets
- All /
« Prev 1 Next »
By not being limited to provide certain arguments/parameters in right order when calling a function, makes the function more versatile and easier to extend without breaking old code (e.g. calls to the function).
One solution is to pass an associati...
0
989
posted 12 years ago by coprolit
With setTimeOut a reference to a function object cannot provide parameters for the scheduled execution of that function.
We can instead use a closure to provide parameters for the execution of a function prior to the execution of that function.
0
687
posted 13 years ago by coprolit
"Javascript module pattern emulates the concept of classes in such a way that we're able to include both public/private methods and variables inside a single object, thus shielding/namespacing particular parts from the global scope."
When inheritanc...
0
936
posted 13 years ago by coprolit
A more flexible version of the 'official' Facebook feed dialog example.
"The Feed Dialog prompts the user to publish an individual story to a profile's feed. This does not require any extended permissions."
"The following simple JavaScript exam...
0
884
posted 14 years ago by coprolit