We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent f3da3d8 commit 422a454Copy full SHA for 422a454
page/plugins/basic-plugin-creation.md
@@ -187,11 +187,13 @@ Here's an example of a small plugin using some of the techniques we've discussed
187
188
$.fn.showLinkLocation = function() {
189
190
- return this.filter( "a" ).each(function() {
+ this.filter( "a" ).each(function() {
191
var link = $( this );
192
link.append( " (" + link.attr( "href" ) + ")" );
193
});
194
195
+ return this;
196
+
197
};
198
199
}( jQuery ));
@@ -217,10 +219,12 @@ Our plugin can be optimized though:
217
219
218
220
221
- return this.filter( "a" ).append(function() {
222
+ this.filter( "a" ).append(function() {
223
return " (" + this.href + ")";
224
225
226
227
228
229
230
0 commit comments