background preloader

CodeSnippets: CodeDrive Snippets courtesy of Peter Coopers handy little app

CodeSnippets: CodeDrive Snippets courtesy of Peter Coopers handy little app

/ public / css This snippet of code will allow you to make your ONTRAPORT forms responsive with just a few minor modifications. Just update your max width (the maximum width you want the form to expand to when on a big screen), and you are good to go! Your form's width will now collapse when viewing on a mobile device without you having to worry about those ugly horizontal scroll bars. f0caca1d2c3cfe9883c88fba6abf1c2a css True False Apr 09, 2014 at 07:41 PM /api/public/snipt/128765/ ontraport-make-your-forms-responsive-with-this-snippet-of-code ONTRAPORT, css CSS check id name someone-text has in name id 268c8fcf236937354144b3d03e4d3b22 Apr 03, 2014 at 11:53 PM /api/public/snipt/127219/ css-check-id-name-someone-text-has-in-name-id Expand Collapse (16 lines) 7412e1e62e0caed3554cbcb34716f2f7 scss

Main Page - GlusterDocumentation Elegant Code Explaining What Action<> And Func<> Are « Making the Complex Simple In C#, Action and Func are extremely useful tools for reducing duplication in code and decreasing coupling. It is a shame that many developers shy away from them because they don’t really understand them. Adding Action and Func to your toolbox is a very important step in improving your C# code. It’s not really that hard to understand what they do and how to use them, it just takes a little patience… A simple way of thinking about Action<> Most of us are pretty familiar with finding sections of repeated code, pulling that code out into a method and making that method take parameters to represent the differences. Here is a small example, which should look pretty familiar: Each one of these methods pretty much does the same thing. It is a simple and common refactor to refactor that code to: Much better, now we aren’t repeating the “actions” in 3 different methods. Now let’s imagine we want to do something more than steam. Probably we will have to add some new methods for doing that.

On the Importance of Purity The benefits of advanced programmings languages are sometimes difficult to grasp for everyday programmers. The features of such languages and how they relate to industrial software development are sometimes hard to understand, especially since the arguments are couched in terms such as "referential transparency", "totality", "side-effect-free", "monads", "non-determinism", "strong static typing", "algebraic data types", "higher-order functions", "laziness/call-by-need", and so on. Many of these features are attributed to "pure" languages, but purity is also a nebulous concept. I will explain the importance of a number of these features and how they impact the everyday programmer's life. The Benefits of Referential Transparency Referential transparency (RT) is a simple principle with profound consequences. This may not sound very significant, but permitting functions which are notRT is literally a nightmare for software developers. The Benefits of Determinism The Benefits of Totality