An open API service indexing awesome lists of open source software.

https://github.com/james2doyle/jquery-plugin-snippets

A bunch of jQuery plugin snippets for Sublime Text 2 via shichuan/javascript-patterns/jquery-plugin-patterns
https://github.com/james2doyle/jquery-plugin-snippets

Last synced: 4 months ago
JSON representation

A bunch of jQuery plugin snippets for Sublime Text 2 via shichuan/javascript-patterns/jquery-plugin-patterns

Awesome Lists containing this project

README

          

jquery-plugin-snippets
======================

A bunch of jQuery plugin snippets for Sublime Text 2 via [shichuan/javascript-patterns/jquery-plugin-patterns](https://github.com/shichuan/javascript-patterns/tree/master/jquery-plugin-patterns)

Clone this repo into the Packages directory of Sublime Text.

Breakdown
---------

* *Basic* - the most basic pattern
* *Extend* - enables you to define multiple functions at once and which sometimes make more sense semantically
* *Lightweight* - perfect as a generic template for beginners and above
* *Namespaced pattern* - to avoid collisions and improve code organization when working with components under another namespace
* *Prototypal inheritance* - prototypal inheritance with the DOM-to-Object bridge pattern
* *Best options* - globally/Per-call overridable options for greater option customization
* *Custom events (Pseudo Pub/Sub)* - for better application decoupling
* *'Highly configurable' mutable* - define plugin’s logic using a constructor and an object literal defined on its prototype
* *UI Widget factory* - for building complex, stateful plugins based on object-oriented principles
* *UI Widget factory "bridge"* - the bridge serves as a middle layer between a JavaScript object that is created using $.widget and jQuery’s API
* *UI Widget factory for jQuery mobile* - demonstrating best practices for building mobile widgets
* *UI Widget + RequireJS module* - for wrapping jQueryUI widgets inside RequireJS compatible modules
* *Universal* Module Definition pattern - create AMD and CommonJS compatible plugin modules which are compatible with a number of different script loaders

References
----------

[shichuan/javascript-patterns](https://github.com/shichuan/javascript-patterns/)

*shichuan references*

[The Essentials of Writing High Quality JavaScript](http://net.tutsplus.com/tutorials/javascript-ajax/the-essentials-of-writing-high-quality-javascript/)

[JSPatterns](http://www.jspatterns.com/)

[jQuery Anti-Patterns for Performance & Compression](http://paulirish.com/2009/perf/)

[How DRY Affects JavaScript Performance](http://velocityconf.com/velocityeu/public/schedule/detail/21634)

[Object Oriented JavaScript](http://www.packtpub.com/object-oriented-javascript/book)

[JavaScript Patterns](http://shop.oreilly.com/product/9780596806767.do)

[JavaScript: The Good Parts](http://shop.oreilly.com/product/9780596517748.do)

[Pro JavaScript Design Patterns](http://jsdesignpatterns.com/)

[Essential JavaScript Design Patterns For Beginners, Volume 1.](http://www.addyosmani.com/resources/essentialjsdesignpatterns/book/)

[Eloquent JavaScript](http://eloquentjavascript.net/)

License
-------

According to [the site](http://shichuan.github.com/javascript-patterns/): "100% Free & taken from somewhere else"

[Source Files](https://github.com/shichuan/javascript-patterns/tree/master/jquery-plugin-patterns)