Put it in its own js file. If you bundle them, it won't be an additional performance hit.
>>You should know that you never repeat code. Create a class called Shared and put it in the Contollers folder.
>>
>>Note: this isn't the best way, but it's easy and gets the job done. Much refactoring would be needed to do things a better way.
>>
>
>I am talking about JavaScript code, not the c# code here. I want to share same function between angularJs controllers which are defined in the same .js file and are in the Scripts folder under particular area.
Craig Berntson
MCSD, Microsoft .Net MVP, Grape City Community Influencer