<?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: Ivan Lesar</title>
    <description>The latest articles on DEV Community by Ivan Lesar (@ilesar).</description>
    <link>https://dev.to/ilesar</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%2F336975%2Fb62d1109-7148-4561-bacb-1ceae78cdc3b.jpeg</url>
      <title>DEV Community: Ivan Lesar</title>
      <link>https://dev.to/ilesar</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/ilesar"/>
    <language>en</language>
    <item>
      <title>Put up fences around your TypeScript modules</title>
      <dc:creator>Ivan Lesar</dc:creator>
      <pubDate>Mon, 04 Jan 2021 23:19:59 +0000</pubDate>
      <link>https://dev.to/bornfightcompany/put-up-fences-around-your-typescript-modules-1ikc</link>
      <guid>https://dev.to/bornfightcompany/put-up-fences-around-your-typescript-modules-1ikc</guid>
      <description>&lt;p&gt;The author says it best...&lt;/p&gt;

&lt;p&gt;"Good Fences is a tool that allows you to segment a &lt;strong&gt;TypeScript&lt;/strong&gt; project into conceptual areas and &lt;strong&gt;manage dependencies&lt;/strong&gt; between those areas."&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/smikula/good-fences"&gt;https://github.com/smikula/good-fences&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Define what you import or export between Typescript files, directories and subdirectories with tagged fence.json files.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;{
    "tags": [ "tagA", "tagB" ],
    "exports": [
        "index",
        {
            "modules": "sample_directory/*",
            "accessibleTo": "tagX"
        }
    ],
    "imports": [
        "tagC",
        "tagD"
    ]
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;And the most important feature... a human readable log with errors.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Good-fences violation in src/foo.ts:
    Import not allowed: src/bar.ts
    Fence: src/fence.json
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;What are your goto tools? Have you stumbled upon anything new and added it to your arsenal? 🧠&lt;/p&gt;

</description>
      <category>engineeringmonday</category>
      <category>codequality</category>
      <category>typescript</category>
      <category>analysis</category>
    </item>
    <item>
      <title>Undocking OSX</title>
      <dc:creator>Ivan Lesar</dc:creator>
      <pubDate>Sat, 30 May 2020 08:17:17 +0000</pubDate>
      <link>https://dev.to/ilesar/undocking-osx-39d5</link>
      <guid>https://dev.to/ilesar/undocking-osx-39d5</guid>
      <description>&lt;h3&gt;
  
  
  The perpetrator
&lt;/h3&gt;

&lt;p&gt;While getting acquainted with the quirks of OSX, one of the things I was immediately not a fan of was the dock. &lt;strong&gt;Spotlight (⌘+space)&lt;/strong&gt; is such a great feature, and it makes the dock just stand in the way.&lt;/p&gt;

&lt;p&gt;The dock wastes your screen surface because maximized applications cannot use the horizontal surface to the sides of it.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fzp4qk1sjt8zo8wvx0t27.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fzp4qk1sjt8zo8wvx0t27.png" alt="Alt Text"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Let's minimize this wasted space by modifying the dock, for the sake of productivity...&lt;/p&gt;

&lt;h3&gt;
  
  
  Ignore it
&lt;/h3&gt;

&lt;p&gt;The first attack vector is to ignore the dock by using the full screen functionality with all apps.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fo64sbam5b5u6cnlnox6z.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fo64sbam5b5u6cnlnox6z.png" alt="Alt Text"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Sure... we'll be using 100% percent of the screen. But we want a permanent solution, not a quick hack.&lt;/p&gt;

&lt;p&gt;If you start using full screen app, you'll probably need to use the three-finger swipe gesture. Even though the gesture seems quick, it might be an illusion. When you have a bunch of apps open, the cmd+tab keystroke requires less hand motion and is as quick as the swipe.&lt;/p&gt;

&lt;p&gt;Moreover, not all apps can be opened in the fullscreen mode, like Adobe Photoshop, for example.&lt;/p&gt;

&lt;p&gt;Not good enough. Let's kick it up a notch! 💪&lt;/p&gt;

&lt;h3&gt;
  
  
  Hide it
&lt;/h3&gt;

&lt;p&gt;Under &lt;em&gt;System Preferences &amp;gt; Dock&lt;/em&gt; you'll find the option to hide the dock.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fonzsfn14do2od7i4srln.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fonzsfn14do2od7i4srln.png" alt="Alt Text"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Great! It doesn't get in the way anymore. We know where we can find it, if we'll need it.&lt;/p&gt;

&lt;h3&gt;
  
  
  Speed it up
&lt;/h3&gt;

&lt;p&gt;But... it seems a bit unresponsive. You hover your mouse to the end bottom of the screen and it appears with a slight delay.&lt;/p&gt;

&lt;p&gt;But have no fear... 🦸🏻‍♂️&lt;/p&gt;

&lt;p&gt;This delay is intentionally set as the default behaviour and it can be overridden by executing two commands in the terminal.&lt;/p&gt;

&lt;p&gt;1) Change the delay value to 0...&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;defaults write com.apple.Dock autohide-delay &lt;span class="nt"&gt;-float&lt;/span&gt; 0
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;


&lt;p&gt;2) Restart the dock for the change to take effect&lt;br&gt;
&lt;/p&gt;
&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;killall Dock
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;


&lt;p&gt;If you'll ever want to revert it, just execute this.&lt;br&gt;
&lt;/p&gt;
&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;defaults delete com.apple.Dock autohide-delay
killall Dock
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;


&lt;p&gt;That's it! We got rid of it and we can instantly bring it back whenever we want to. 100% screen real estate. Mission accomplished! 😎&lt;/p&gt;
&lt;h3&gt;
  
  
  Question it
&lt;/h3&gt;

&lt;p&gt;Hmmm... but why are we even using the dock if we can leave our hands on the keyboard and use these keystrokes?&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;⌘+space&lt;/strong&gt; to open the apps&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;⌘+tab&lt;/strong&gt; to switch between apps&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;⌘+Q&lt;/strong&gt; to quit apps&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;A whole lot of redundancy going on.&lt;/p&gt;
&lt;h3&gt;
  
  
  End it.
&lt;/h3&gt;

&lt;p&gt;Let's face it.&lt;/p&gt;

&lt;p&gt;We might as well declare the dock obsolete. The Apple touchpad and keyboard evolved over the years, with the dock evolving from one of the most recognisable OSX visual characteristics to a screen-cluttering distraction.&lt;/p&gt;

&lt;p&gt;The time has come...&lt;/p&gt;

&lt;p&gt;Good night, sweet prince.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://i.giphy.com/media/T2po0QVqNpN84/giphy.gif" class="article-body-image-wrapper"&gt;&lt;img src="https://i.giphy.com/media/T2po0QVqNpN84/giphy.gif" alt="nighty night"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;🥇 I challenge you to hide it for a week and try not to use it.&lt;/p&gt;

&lt;p&gt;I made a gist which you can fork so you can easily find the delay rollback command later.&lt;/p&gt;


&lt;div class="ltag_gist-liquid-tag"&gt;
  
&lt;/div&gt;



</description>
      <category>productivity</category>
      <category>osx</category>
      <category>screen</category>
      <category>dock</category>
    </item>
  </channel>
</rss>
