<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Vikram Ramanujam</title>
    <description>The latest articles on DEV Community by Vikram Ramanujam (@vviikk).</description>
    <link>https://dev.to/vviikk</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F112094%2F8b743887-05ae-4f46-8f55-21f7f700c530.jpg</url>
      <title>DEV Community: Vikram Ramanujam</title>
      <link>https://dev.to/vviikk</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/vviikk"/>
    <language>en</language>
    <item>
      <title>A take on immutability in CSS Custom properties</title>
      <dc:creator>Vikram Ramanujam</dc:creator>
      <pubDate>Sun, 25 Nov 2018 06:16:40 +0000</pubDate>
      <link>https://dev.to/vviikk/a-take-on-immutability-in-css-custom-properties-14n6</link>
      <guid>https://dev.to/vviikk/a-take-on-immutability-in-css-custom-properties-14n6</guid>
      <description>

&lt;p&gt;Originally on &lt;a href="https://medium.com/@piggyslasher/to-add-to-this-heres-a-way-to-achieve-immutability-in-css-custom-properties-35ce6908f8d"&gt;Medium.com&lt;/a&gt; as a reply to &lt;a href="https://calidae.blog/css-in-defense-of-important-d82393f81a5"&gt;CSS: In defense of !important – Calidae Blog&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;Debugging custom properties &amp;amp; &lt;code&gt;calc()&lt;/code&gt; functions are not the best DX (Developer experience), yet. One way is to enforce good coding practices to help avoid issues. One of those reasons - is enforcing immutability.&lt;/p&gt;

&lt;p&gt;Please read the article and let me know if you see more benefits that I might have overlooked!&lt;/p&gt;

&lt;p&gt;&lt;iframe height="600" src="https://codepen.io/piggyslasher/embed/OaWpmQ?height=600&amp;amp;default-tab=result&amp;amp;embed-version=2"&gt; &lt;/iframe&gt;&lt;/p&gt;


</description>
      <category>csscustomproperties</category>
      <category>cssvariables</category>
      <category>immutablecss</category>
    </item>
    <item>
      <title>Completely configurable, flexible, re-usable CSS-only checkbox toggles</title>
      <dc:creator>Vikram Ramanujam</dc:creator>
      <pubDate>Tue, 06 Nov 2018 10:10:58 +0000</pubDate>
      <link>https://dev.to/vviikk/flexible-re-usable-css-only-checkboxes-g54</link>
      <guid>https://dev.to/vviikk/flexible-re-usable-css-only-checkboxes-g54</guid>
      <description>&lt;p&gt;Configurable using CSS Custom properties!. Found a lot of great examples of toggles around the web, but all of them had some form of hard-coded values. Check out the code. Uses line-height and follows the natural sizing given to it. Feel free to steal :)&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight"&gt;&lt;pre class="highlight html"&gt;&lt;code&gt;  &lt;span class="nt"&gt;&amp;lt;input&lt;/span&gt; &lt;span class="na"&gt;class=&lt;/span&gt;&lt;span class="s"&gt;"switch"&lt;/span&gt; &lt;span class="na"&gt;id=&lt;/span&gt;&lt;span class="s"&gt;"switch-55"&lt;/span&gt; &lt;span class="na"&gt;type=&lt;/span&gt;&lt;span class="s"&gt;"checkbox"&lt;/span&gt;&lt;span class="nt"&gt;/&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;label&lt;/span&gt; &lt;span class="na"&gt;for=&lt;/span&gt;&lt;span class="s"&gt;"switch-55"&lt;/span&gt; &lt;span class="na"&gt;style=&lt;/span&gt;&lt;span class="s"&gt;"
    --switch-width: 3rem; /* optional properties */
    --switch-knob-size: .8rem;
  "&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;Toggle&lt;span class="nt"&gt;&amp;lt;/label&amp;gt;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;





&lt;div class="highlight"&gt;&lt;pre class="highlight css"&gt;&lt;code&gt;&lt;span class="c"&gt;/* the following properties are configurable by simply overriding them: */&lt;/span&gt;
&lt;span class="o"&gt;:&lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;  
  &lt;span class="py"&gt;--switch-background&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="no"&gt;silver&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="py"&gt;--switch-background-active&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="no"&gt;mediumseagreen&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="py"&gt;--switch-width&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;3ch&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="py"&gt;--switch-knob-size&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;calc&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;var&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;--switch-width&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;/&lt;/span&gt; &lt;span class="m"&gt;3&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
  &lt;span class="py"&gt;--switch-knob-offset&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;calc&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="m"&gt;50%&lt;/span&gt; &lt;span class="n"&gt;-&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;var&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;--switch-knob-size&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;/&lt;/span&gt; &lt;span class="m"&gt;2&lt;/span&gt;&lt;span class="p"&gt;));&lt;/span&gt;
  &lt;span class="py"&gt;--switch-knob-color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="no"&gt;white&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="py"&gt;--switch-transition-duration&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;0.3s&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;



&lt;p&gt;&lt;iframe height="600" src="https://codepen.io/piggyslasher/embed/rNaPKve?height=600&amp;amp;default-tab=result&amp;amp;embed-version=2"&gt;
&lt;/iframe&gt;
&lt;/p&gt;

</description>
      <category>cssonly</category>
      <category>checkboxhack</category>
      <category>siblingselector</category>
      <category>nojs</category>
    </item>
    <item>
      <title>The state of CSS, CSS in JS and how styled-components is solving problems we've had for decades.</title>
      <dc:creator>Vikram Ramanujam</dc:creator>
      <pubDate>Mon, 05 Nov 2018 12:13:08 +0000</pubDate>
      <link>https://dev.to/vviikk/the-state-of-css-css-in-js-and-how-styled-components-is-solving-problems-weve-had-for-decades-1pbn</link>
      <guid>https://dev.to/vviikk/the-state-of-css-css-in-js-and-how-styled-components-is-solving-problems-weve-had-for-decades-1pbn</guid>
      <description>

&lt;p&gt;Originally published on &lt;a href="https://medium.com/@piggyslasher/the-state-of-css-css-in-js-how-styled-components-is-solving-the-problems-weve-had-for-decades-d8abbc8bc148"&gt;Medium.com&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;I was hoping to write about what CSS has become, but I had to start with the origins. I hope you like my findings. And there are a few cool things I've learnt along the way for you to play about with:)&lt;/p&gt;


</description>
      <category>styledcomponents</category>
      <category>css</category>
      <category>cssinjs</category>
      <category>react</category>
    </item>
  </channel>
</rss>
