...s calc(100 - l)); Here is what happens: from currentColor tells hsl() to start with the value of currentColor. calc(h + 180) rotates the color hue by 180 degrees, i.e...
...to the opposite of the color wheel. s keeps saturation unchanged. calc(100 - l) inverts lightness. For example, 0% becomes 100%, and 100% becomes 0%. Example usage .demo { --inverted-color...
...implementation changes. The information below is validated for the current list of browsers we support. By default your html and body elements are only as high as the actual page...
...html and body elements will only be around 40 pixels high, regardless of the size of your browser window. You might be surprised by this, since setting a background on...
...possible to only use -f pretty for the rerun. Drawbacks: MAJOR: With our current setup, when the main run fails without writing a tmp/failing_features.txt (e.g. due to a syntax error...
...the CI job will pass MINOR: With our current setup, we lose the test coverage of the main run A fix for the passing CI despite syntax error could look...
This is super stupid: In the Thunar file manager, select the file Go to File / Properties / Open With (WTF!) Select the preferred application from the list and hit "Set default...
...This setting will apply to all files with that extension...
...desktop users may encounter some weird quirks: Aside from allowing only digits and decimal separators, an "e" is also allowed (to allow scientific notation like "1e3"). Non-technical users will...
...be confused by this. Your server needs to understand that syntax. If it converts only digits (e.g. to_i in Ruby) you'll end up with wrong values (like...
When building an application that sends e-mails to users, you want to avoid those e-mails from being classified as spam. Most obvious scoring issues will not be relevant...
...to you because you are not a spammer. However, your application must do one thing by itself: When sending HTML e-mails, you should include a plain-text body or...
In your ~/.gitconfig: [core] editor=nano
Event delegation is a pattern where a container element has a single event listener that handles events for all descendants that match a CSS selector. This pattern was popularized by...
...element was clicked!") }) This technique has some advantages: When you have many descendants, you save time by only registering a single listener. When the descendants are changed dynamically via JavaScript...
...config={}). There also is a generate method which will run the generator in a subprocess. Call it with generate 'generator_name', 'command line args'. Expected (hard-coded) directory structure of...
... #{generator name, e.g. model}_generator.rb USAGE Templates If you want to use the supplied template, directory and other template methods, you must call source_root 'path/to/templates' inside your generator...
Both knapsack and parallel_tests have the option to split groups by historic execution time. The required logs for this might be outdated since you manually have to update and...
...consistently up to date with no extra effort locally and/or remotely. How to always split by execution logs Parallel Tests The parallel_tests gem has the option flag --group-by...
Settings -> Editor -> General -> Smart Keys -> Unindent -> To nearest indent position RubyMine 7.0: Settings -> Editor -> General -> Smart Keys -> Backspace smart indent -> uncheck
With ActiveSupport you can say: class Robot def self.likes_humans? 'Nope.' end delegate :likes_humans?, to: :class end Robot.likes_humans? # => 'Nope.' Robot.new.likes_humans?
This article will show you how to use throw and catch. It's a nice tool to break out of multiple loops when a result is obtained.
...card Ruby: A small summary of what return, break and next means for blocks...
brandcolors.net provides you with the colors of the world's biggest brands, easily searchable...
How you can unknowingly screw your client's business when all you think about is closing the next user story...
Rails 4.0 introduced a helpful new method for ActiveRecord queries: where.not. It can make clunky queries easier to read.
About Chrome's network stack and optimizations to load web pages faster...
Makes a robust determination of a user's timezone through Javascript.
How to make class_attribute behave like class_inheritable_attribte which no longer exists in Rails.
Chrome now supports desktop notifications using WebKit's webkitNotifications API. This means you can create popup bubbles from Javascript...
Ubuntu natty introduced new "invisible" scrollbars for GTK programs such as gEdit or Nautilus. If you do not like them: sudo apt-get purge liboverlay-scrollbar-* In order to have...
File upload solution that supports form roundtrips when a validation fails...
...This release has many minor changes and fixes to prepare your application for Rails 3. Step-by-step upgrade instructions: Upgrade rails gem Change your environment.rb so it says RAILS...
...for a detailed list of changes. 2.3.9 to 2.3.10 Fixes Vulnerability in Nested Attributes code. Step-by-step upgrade instructions: Upgrade rails gem Change your environment.rb so it says RAILS...
...issues, depending on the exact version, and depending on your app. However, it is still possible to give some generic advice on how you want to tackle the update in...
...really confident about upgrading Rails, have a look at Rails LTS. How many update steps? Besides the Rails upgrade itself, you might also want to upgrade your other gems and...