autosize icon indicating copy to clipboard operation
autosize copied to clipboard

Added AngularJs support

Open aqzhyi opened this issue 12 years ago • 3 comments

I just added AngularJs support. Becuse I love it.

aqzhyi avatar May 12 '13 17:05 aqzhyi

Thanks for suggest.

I just suggest a AngularJs way to implement this plugin. And I used it for my project too.

Yes, the autosize name is bad directive name.

In fact, I am AngularJs beginner, so I have no idea how define the directive name.

Other popular AngularJs directive usually had a prefix like ui-hide, ui-show, ui-mask etc.

And this plugin is Jack Moore's plugin, so I don't know what name or prefix he like.

So I think, the directive name, it's for Jack Moore to decide, maybe better.

aqzhyi avatar May 13 '13 14:05 aqzhyi

I just suggest a AngularJs way to implement this plugin.

Yes, and it's a great suggestion!

Yes, the autosize name is bad directive name. And this plugin is Jack Moore's plugin, so I don't know what name or prefix he like.

Indeed, it is his. However, I'm sure Jack doesn't want to include an example that might lead to other developers having to spend 45 minutes trying to debug JavaScript. :sweat: How about, at least, updating it to jqueryAutosize for now? Would you like me to make a pull request to you?

In fact, I am AngularJs beginner,

So am I.

so I have no idea how define the directive name.

You can define it either way you want. Usually, you add a common prefix for a single Angular module (ui- in the AngularUI case, ng- in the AngularJS case). In the case of autosize, there's only one directive, so it's not that important.

JensRantil avatar May 13 '13 15:05 JensRantil

Thanks, I got it.

aqzhyi avatar May 13 '13 16:05 aqzhyi