Skip to main content

Ricardo Amaral

Member since Jan 31, 2015

Recent Blog Comments By Ricardo Amaral

  • Creating And Extending A Lodash / Underscore Service In AngularJS

    Posted on Feb 1, 2015 at 6:14 AM

    @Ricardo, I remembered a small issue with my implementation, $provide.value is going to create a mutable value, which allows anyone to rewrite it anywhere. However, I tried the same for a constant and factory and I could still rewrite the lodash injection in one place and then get an undefined erro... read more »

  • Creating And Extending A Lodash / Underscore Service In AngularJS

    Posted on Jan 31, 2015 at 5:20 PM

    I'm not fond of the idea of injecting '_' on run() just to clear the global scope. What about the following approach: app.config(['$provide', function ($provide) { $provide.value('_', window._); delete window._; }]); I know I'm using the global 'window' instead of '$window' but it's just f... read more »

I believe in love. I believe in compassion. I believe in human rights. I believe that we can afford to give more of these gifts to the world around us because it costs us nothing to be decent and kind and understanding. And, I want you to know that when you land on this site, you are accepted for who you are, no matter how you identify, what truths you live, or whatever kind of goofy shit makes you feel alive! Rock on with your bad self!
Ben Nadel