<?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>Forem: Chris Achard</title>
    <description>The latest articles on Forem by Chris Achard (@chrisachard).</description>
    <link>https://forem.com/chrisachard</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%2F212474%2F928651b2-e082-4350-aeb3-25a861a8aa76.png</url>
      <title>Forem: Chris Achard</title>
      <link>https://forem.com/chrisachard</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://forem.com/feed/chrisachard"/>
    <language>en</language>
    <item>
      <title>Learn redux-toolkit in 10 steps</title>
      <dc:creator>Chris Achard</dc:creator>
      <pubDate>Tue, 15 Dec 2020 14:23:23 +0000</pubDate>
      <link>https://forem.com/chrisachard/learn-redux-toolkit-in-10-steps-2g88</link>
      <guid>https://forem.com/chrisachard/learn-redux-toolkit-in-10-steps-2g88</guid>
      <description>&lt;p&gt;This was originally posted as a tweet thread: &lt;a href="https://twitter.com/chrisachard/status/1338507383765684224" rel="noopener noreferrer"&gt;&lt;/a&gt;&lt;a href="https://twitter.com/chrisachard/status/1338507383765684224" rel="noopener noreferrer"&gt;https://twitter.com/chrisachard/status/1338507383765684224&lt;/a&gt;&lt;br&gt;
&lt;br&gt;&lt;/p&gt;

&lt;p&gt;If you're using redux today, you should be using redux-toolkit&lt;/p&gt;

&lt;p&gt;Here's redux-toolkit in 10 steps 👇&lt;/p&gt;

&lt;h2&gt;
  
  
  1.
&lt;/h2&gt;

&lt;p&gt;Create a "store" with "configureStore"&lt;/p&gt;

&lt;p&gt;A store holds all your data and the actions that change that data&lt;/p&gt;

&lt;p&gt;Use a "Provider" component (like context) to give the store to all your components&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%2Ffvavkbkcjjgwk6hiks98.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%2Ffvavkbkcjjgwk6hiks98.png" alt="Provider gives the store to any component below it in the app. configureStore can also configure middleware and enhancers"&gt;&lt;/a&gt;&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%2Frjb5tevurbj58y631mn3.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%2Frjb5tevurbj58y631mn3.png" alt="All your data and actions to update that data. Divided into slices. All components under the Provider have access to any data or actions in the store"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  2.
&lt;/h2&gt;

&lt;p&gt;Create named "slices"&lt;/p&gt;

&lt;p&gt;A slice holds a chunk of the state, plus the functions that can update that state&lt;/p&gt;

&lt;p&gt;No more changing 4 different files just to write one action! 🎉&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%2Fhld6ds57v1thss1riubx.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%2Fhld6ds57v1thss1riubx.png" alt="Each slice has a name. State can contain any serializable data that you want (strings, objects, arrays, etc). Reducers auto-create actions No need for 4 different files  just for 1 action!"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  3.
&lt;/h2&gt;

&lt;p&gt;Add the slice to your store by adding the "reducer" from the slice to the "reducer" in the store&lt;/p&gt;

&lt;p&gt;The slice ".reducer" (singular) is auto-created when you define your "reducers:" (plural) in the slice&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%2Fp810ceofsj5q03clltrt.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%2Fp810ceofsj5q03clltrt.png" alt="Specify the reducer name (same as your slice name). Add multiple slices by adding multiple keys to the object. Each slice has a "&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  4.
&lt;/h2&gt;

&lt;p&gt;Functions that update the state in your slice are "reducers"&lt;/p&gt;

&lt;p&gt;A reducer takes the current state and the action (data) being performed, &lt;/p&gt;

&lt;p&gt;and updates the data in the slice's state&lt;/p&gt;

&lt;p&gt;(redux-toolkit uses immer, so those state changes are actually non-mutating)&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%2Fnlr7wjnz234q7sjgtthb.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%2Fnlr7wjnz234q7sjgtthb.png" alt="Reducers are functions that take the current state and change it. This LOOKS like a mutating change but since redux-toolkit uses immer, it’s actually a non-mutating change. Functions in this reducers object are auto-exported as "&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  5.
&lt;/h2&gt;

&lt;p&gt;To get values from the store in a component, use a "selector"&lt;/p&gt;

&lt;p&gt;A selector function is given the entire redux store and returns just the data you want&lt;/p&gt;

&lt;p&gt;Pass your selector to the "useSelector" hook which will call it for you&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%2Fznjlrhdkbdgb0ct2ozzz.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%2Fznjlrhdkbdgb0ct2ozzz.png" alt="You can use useSelector in any component in the tree under a Provider component. The entire redux store. Access your named slice. Get any value from that slice. Then use that value like any other value in JSX"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  6.
&lt;/h2&gt;

&lt;p&gt;To change data in the store, use the "actions" that are exported from the slice&lt;/p&gt;

&lt;p&gt;These actions are named based on your named reducers&lt;/p&gt;

&lt;p&gt;You don't call on their own however, because they need the current state and action params&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%2Fs306yio4ge83ywr9wu8j.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%2Fs306yio4ge83ywr9wu8j.png" alt="actions are created based on your reducers in your slice. actions are functions, but don’t call them directly - they have to be dispatched"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  7.
&lt;/h2&gt;

&lt;p&gt;To call the action, you "dispatch" it to the store&lt;/p&gt;

&lt;p&gt;Use the "useDispatch" hook to get access to the "dispatch" function&lt;/p&gt;

&lt;p&gt;then dispatch your action using that function&lt;/p&gt;

&lt;p&gt;this automatically updates all components using "useSelector"&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%2F6nyezudcy84c6hd9dbr7.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%2F6nyezudcy84c6hd9dbr7.png" alt="useDispatch can be used in any component under the Provider. dispatch is a function that takes the result of calling your actions. Make sure to call your action functions!. Then onClick, this will dispatch the "&gt;&lt;/a&gt;&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%2F3mrwcfpb351pa275gibe.gif" 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%2F3mrwcfpb351pa275gibe.gif" alt="A counter counting up"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  8.
&lt;/h2&gt;

&lt;p&gt;Actions can take params as well, which are passed in as the second argument to the reducer&lt;/p&gt;

&lt;p&gt;the action "payload" will contain whatever is passed to the action&lt;/p&gt;

&lt;p&gt;(to pass multiple params, use an object)&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%2Ffo7qeiq7ikymficabbi1.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%2Ffo7qeiq7ikymficabbi1.png" alt="The dispatched action comes across as the second argument to the reducer functions. The action payload contains the params passed to the  action function"&gt;&lt;/a&gt;&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%2Fweikb7ga0dp6fg5602l6.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%2Fweikb7ga0dp6fg5602l6.png" alt="Your actions can now take params and pass those values to the reducers as the "&gt;&lt;/a&gt;&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%2F3hb393jb8od2wlktyg00.gif" 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%2F3hb393jb8od2wlktyg00.gif" alt="A counter going up and down by ones and fives"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  9.
&lt;/h2&gt;

&lt;p&gt;For async actions (like fetching data), you can use redux-thunk (already included!)&lt;/p&gt;

&lt;p&gt;Create a thunk (function that returns a function)&lt;/p&gt;

&lt;p&gt;it's async and gets dispatch as a param&lt;/p&gt;

&lt;p&gt;dispatch inside your thunk function&lt;/p&gt;

&lt;p&gt;Then dispatch that action like normal in component&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%2Foj54lyb9rks35i2nzmka.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%2Foj54lyb9rks35i2nzmka.png" alt="A thunk is a function that returns a function. The returned function will get immediately called and given dispatch as a param. Perform async actions like data fetching. Then dispatch whenever your data is ready"&gt;&lt;/a&gt;&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%2Fhk8w9mc6j471h62d9xru.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%2Fhk8w9mc6j471h62d9xru.png" alt="Your thunk can then be dispatched like any other action!"&gt;&lt;/a&gt;&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%2F8stpahv01hpeknw6xmbv.gif" 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%2F8stpahv01hpeknw6xmbv.gif" alt="Counter counting up by 1, and then counting up by the length of text returned by localhost"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  10.
&lt;/h2&gt;

&lt;p&gt;What about just using Context instead?&lt;/p&gt;

&lt;p&gt;Yes, I generally start projects with just context, but redux can have some advantages for larger projects or teams:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;provides structure that context doesn't&lt;/li&gt;
&lt;li&gt;can be easier to test&lt;/li&gt;
&lt;li&gt;redux dev tools are pretty cool 💯&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Resources
&lt;/h2&gt;

&lt;p&gt;Code for this example:&lt;br&gt;
&lt;a href="https://github.com/chrisachard/redux-toolkit-example" rel="noopener noreferrer"&gt;https://github.com/chrisachard/redux-toolkit-example&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Quick start redux-toolkit docs:&lt;br&gt;
&lt;a href="https://redux-toolkit.js.org/introduction/quick-start" rel="noopener noreferrer"&gt;https://redux-toolkit.js.org/introduction/quick-start&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Redux devtools chrome extension:&lt;br&gt;
&lt;a href="https://github.com/zalmoxisus/redux-devtools-extension" rel="noopener noreferrer"&gt;https://github.com/zalmoxisus/redux-devtools-extension&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;The current redux maintainer and general keeper of many links:&lt;br&gt;
&lt;a href="https://twitter.com/acemarke" rel="noopener noreferrer"&gt;https://twitter.com/acemarke&lt;/a&gt;&lt;/p&gt;



&lt;h3&gt;
  
  
  Like this post?
&lt;/h3&gt;

&lt;p&gt;Check me out on twitter!  I post software dev tips and threads there: &lt;a href="https://twitter.com/chrisachard" rel="noopener noreferrer"&gt;https://twitter.com/chrisachard&lt;/a&gt; 🙌&lt;/p&gt;

</description>
      <category>react</category>
      <category>javascript</category>
      <category>redux</category>
      <category>webdev</category>
    </item>
    <item>
      <title>Why We Buy Domain Names (and what to do about it)</title>
      <dc:creator>Chris Achard</dc:creator>
      <pubDate>Wed, 27 May 2020 16:15:26 +0000</pubDate>
      <link>https://forem.com/chrisachard/why-we-buy-domain-names-and-what-to-do-about-it-4hl6</link>
      <guid>https://forem.com/chrisachard/why-we-buy-domain-names-and-what-to-do-about-it-4hl6</guid>
      <description>&lt;p&gt;&lt;em&gt;This post was originally published on: &lt;a href="https://make.dev/blog/why-we-buy-domain-names"&gt;https://make.dev/blog/why-we-buy-domain-names&lt;/a&gt;&lt;/em&gt;&lt;/p&gt;

&lt;p&gt; &lt;/p&gt;

&lt;p&gt;You have an idea.  It's an AMAZING idea.&lt;/p&gt;

&lt;p&gt;You think of a domain name. It's an AMAZING domain name, and it's AVAILABLE!&lt;/p&gt;

&lt;p&gt;Your mind starts racing:&lt;/p&gt;

&lt;p&gt;"This is it! I can make this and turn it into something awesome. I can see exactly what it would look like in my head - it's going to be so cool! I'd better snap up that domain name before someone else does.  Hm; I guess I'd better register the twitter, instagram and youtube accounts too..."&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;So you buy it&lt;/strong&gt;.  You have the domain name, the twitter account, a shiny new email address...&lt;/p&gt;

&lt;p&gt;...and then three months later you've done exactly nothing on the project 🤦‍♂️&lt;/p&gt;

&lt;p&gt;So the name gets put on the pile of other names - a graveyard of projects that you'll get to eventually.  It sits in a list of old ideas tormenting you until it expires.  UGH.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;WHY?&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Why do we do this to ourselves?  And, perhaps more importantly, what can we do to stop the cycle?&lt;/p&gt;

&lt;h2&gt;
  
  
  Loss Aversion
&lt;/h2&gt;

&lt;p&gt;The sharpest pain we feel is loss aversion.  &lt;/p&gt;

&lt;p&gt;If you don't buy this domain name RIGHT NOW - then someone else will.&lt;/p&gt;

&lt;p&gt;They will steal your amazing idea, and then they will get all the credit, and then you'll be forced to get a stupid name instead, and then the project will never reach its true potential.&lt;/p&gt;

&lt;p&gt;We feel like once we've found a good name, it's &lt;strong&gt;OURS&lt;/strong&gt; - even before we've bought it - and if someone else buys it first, then they've &lt;em&gt;taken something of ours&lt;/em&gt;.&lt;/p&gt;

&lt;p&gt;It's even worse when we start imagining our amazing project or company that will live at that domain name.  We start to imagine the success of a project before we've done any work on it and (of course), the domain name is the first step in that project's journey, right?  So if we lose the domain name then we've lost that entire great future as well.&lt;/p&gt;

&lt;h3&gt;
  
  
  What do do about it
&lt;/h3&gt;

&lt;p&gt;First: just because YOU are on the verge of buying it - doesn't mean that anyone else is.  You can wait a week... it's ok; the domain name will probably still be there in a week.&lt;/p&gt;

&lt;p&gt;Second: realize that just because you thought of it first, &lt;em&gt;doesn't mean it's yours&lt;/em&gt;!  You're imagining what the name WILL mean in the future, and not recognizing it for what it is right now: a commodity that anyone can buy or sell.&lt;/p&gt;

&lt;p&gt;Lastly: understand what is happening in your brain.  You're becoming attached to something you THINK is going to happen.  Instead, try to remind yourself of all the work that would be ahead of you to make that a reality - and that future isn't yours yet.&lt;/p&gt;

&lt;h2&gt;
  
  
  Good domains are hard to find
&lt;/h2&gt;

&lt;p&gt;The reason we feel loss aversion so strongly is because it's really hard to find a good domain name!  Aren't they all taken already?&lt;/p&gt;

&lt;p&gt;So, when we find a short, pronounceable name that perfectly describes the project, of course we're going to feel attached to it!  We've already spent so much time thinking up a good name for it!&lt;/p&gt;

&lt;p&gt;There are at least two ways that thinking is twisted though:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;&lt;p&gt;Sunk cost fallacy - just because you've spent a lot of time finding a good name, doesn't mean it's ACTUALLY a good name, or that it's the best name for your project, &lt;em&gt;or even that the project is actually a good idea in the first place&lt;/em&gt;.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Good domain names &lt;strong&gt;are everywhere&lt;/strong&gt; - it FEELS like good names are in short supply, but there hundreds of TLDs and millions of word combinations that are undiscovered.&lt;/p&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;h3&gt;
  
  
  What to do about it
&lt;/h3&gt;

&lt;p&gt;Remind yourself that there are THOUSANDS of domain names that &lt;a href="https://www.expireddomains.net/"&gt;expire every single day&lt;/a&gt;.  Every single one of those was bought by someone who thought it was a good idea... but then a year, two years, 10 years later - they let the domain go.  Do you want to be one of those expired names?&lt;/p&gt;

&lt;p&gt;Also, remember that .com isn't the only option!  TONS of great companies have been built on .co, .io, .app, and now there are 100s more to choose from.  People don't really type in domain names now anyway - they search for it, or click a link from somewhere.&lt;/p&gt;

&lt;h2&gt;
  
  
  Short term dopamine hit
&lt;/h2&gt;

&lt;p&gt;Buying a domain name FEELS good.  It feels like progress.&lt;/p&gt;

&lt;p&gt;Buying a domain name is fun, (more fun than the actual work of making the thing), so that's what we do first.  Once we give a name to a project it feels real - feels like we've done the first step on a great journey.  &lt;/p&gt;

&lt;p&gt;What we're really doing is giving our brain a quick hit of dopamine - the same quick hit you get when you impulse buy something in the checkout line at a store.&lt;/p&gt;

&lt;p&gt;We're not making progress on the real substance of the project, but instead just doing all the ancillary things that we want to do to make us feel good about starting.  &lt;/p&gt;

&lt;p&gt;This isn't a fake feeling by the way: it's a real, chemical reaction in our brains that makes us feel amazing... but it's misleading.  &lt;/p&gt;

&lt;p&gt;It will lead you down the wrong road.&lt;/p&gt;

&lt;h3&gt;
  
  
  What to do about it
&lt;/h3&gt;

&lt;p&gt;The most important thing to do is recognize it for what it is: a short term hit that will make you feel good for a minute, until the reality of the project sets in.  Just realizing that isn't enough though - we have to train our brains to ignore or delay that impulse.&lt;/p&gt;

&lt;p&gt;Try this exercise &lt;em&gt;(WARNING! this is dangerous)&lt;/em&gt;:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;&lt;p&gt;Go to &lt;a href="https://leandomainsearch.com/"&gt;https://leandomainsearch.com/&lt;/a&gt; and search for a common, short word like "nice".  &lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Now, LOOK AT ALL THOSE GOOD DOMAIN NAMES  (I personally like "NiceZap.com" and "NiceDigest.com")&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Here's the hard part: DON'T BUY ANY!&lt;/p&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Congrats 🎉 you've just trained your brain a little bit to look at some good names, and then not buy them.&lt;/p&gt;

&lt;p&gt;Also, if you do this enough you'll realize that there are HUNDREDS of good domain names still available.  Names aren't really in short supply: that's just an illusion.&lt;/p&gt;

&lt;h2&gt;
  
  
  So what should you do?
&lt;/h2&gt;

&lt;p&gt;You still want to start cool new projects, so what are you supposed to do: just NOT buy that cool domain name you've found?&lt;/p&gt;

&lt;p&gt;Here are the three ways I see it:&lt;/p&gt;

&lt;h3&gt;
  
  
  Create one unified brand name for all your side projects
&lt;/h3&gt;

&lt;p&gt;A lot of people use "myname.com", which is pretty good, and has the benefit that you can launch "myname.com/cool-project", even if "cool-project" already exists in the world.&lt;/p&gt;

&lt;p&gt;If you have a single, broad name for all your projects, you get several benefits:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;&lt;p&gt;You don't have to register new names + twitter accounts + emails for every single project you start.  Time savings!&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;You'll save money on domain names&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;You don't get the dopamine hit from finding a good name and registering it; instead, you're forced to actually work ON the project.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;If a project does take off, and you want to peel it off in the future, nothing is stopping you!  &lt;/p&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Just wait until after there is real forward progress.&lt;/p&gt;

&lt;h3&gt;
  
  
  Wait 7 days before buying any new name
&lt;/h3&gt;

&lt;p&gt;Maybe you REALLY want that name though - ok, ok - but just wait a bit until you buy it.&lt;/p&gt;

&lt;p&gt;It will almost certainly be available in a week, so wait a week and then ask: "Do I still really want this?"&lt;/p&gt;

&lt;p&gt;I'll bet for more than half of those domain names, you won't really care a week later.&lt;/p&gt;

&lt;p&gt;There are two big downsides to this approach though: &lt;/p&gt;

&lt;p&gt;First, &lt;strong&gt;what if someone DOES buy the name?&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Well, they probably won't.  But you do have to be ready for that, so figure out how you're going to feel about that NOW, and try accept that feeling before it happens.  That way if you don't get the domain, you'll be ready for it, but if you DO get it, then you can be super excited.&lt;/p&gt;

&lt;p&gt;Second, it can &lt;strong&gt;limit your forward progress&lt;/strong&gt; if you let it.  &lt;/p&gt;

&lt;p&gt;If you think that setting up a website is the first step to complete a project, then delaying that will delay the project.  RIGHT?  &lt;/p&gt;

&lt;p&gt;The remedy for that is to realize that setting up a domain name should NOT be the first step in a project. &lt;/p&gt;

&lt;p&gt;There is SO MUCH WORK that has to be done for any project, and a domain name isn't need until a ways down the line.&lt;/p&gt;

&lt;h3&gt;
  
  
  Say "Screw It", and buy the domain name anyway
&lt;/h3&gt;

&lt;p&gt;Ok, so this may be counter productive in a post that is trying to help break a habit... but sometimes buying that domain name is ok.&lt;/p&gt;

&lt;p&gt;It can be a cheap way to get a dopamine hit, and they (usually) don't cost that much.  So give yourself some slack.&lt;/p&gt;

&lt;p&gt;But there are a few things that you'll have to accept:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;&lt;p&gt;You'll have to stare a list of domains that you aren't using, and then let them expire when you're done with them. That part can hurt.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;They renew every year... so that can reallllly add up!  Recurring charges are dangerous.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Mental overhead: How many projects are you still thinking about starting from 2 years ago that you haven't gotten around to yet?  That can be really distracting.&lt;/p&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;h2&gt;
  
  
  Make awesome things
&lt;/h2&gt;

&lt;p&gt;Whether you choose to keep buying domain names or not, I think it's great that the urge to create drives us.&lt;/p&gt;

&lt;p&gt;Figure out if you can make peace with your growing list of unused domain names, or if you should use some of the tactics here to try to prevent the purchase in the first place.  &lt;/p&gt;

&lt;p&gt;Try to &lt;strong&gt;be kind to yourself though:&lt;/strong&gt; it's hard to change your behavior.&lt;/p&gt;

&lt;p&gt;And: keeping making awesome things 🦄&lt;/p&gt;

&lt;p&gt; &lt;br&gt;
 &lt;/p&gt;

&lt;h3&gt;
  
  
  Like this post?
&lt;/h3&gt;

&lt;p&gt;🔥 Get one startup tip every weekday in a free newsletter: &lt;a href="https://make.dev"&gt;https://make.dev&lt;/a&gt;&lt;/p&gt;

&lt;p&gt; &lt;/p&gt;

</description>
      <category>startup</category>
      <category>productivity</category>
    </item>
    <item>
      <title>Tips for Organizing React Projects</title>
      <dc:creator>Chris Achard</dc:creator>
      <pubDate>Wed, 18 Mar 2020 11:42:17 +0000</pubDate>
      <link>https://forem.com/chrisachard/tips-for-organizing-react-projects-191</link>
      <guid>https://forem.com/chrisachard/tips-for-organizing-react-projects-191</guid>
      <description>&lt;p&gt;&lt;i&gt;This was originally posted as a twitter thread: &lt;a href="https://twitter.com/chrisachard/status/1239993582397816838"&gt;&lt;/a&gt;&lt;a href="https://twitter.com/chrisachard/status/1239993582397816838"&gt;https://twitter.com/chrisachard/status/1239993582397816838&lt;/a&gt;&lt;/i&gt;&lt;/p&gt;

&lt;h1&gt;There is no &lt;i&gt;One Way&lt;/i&gt;
&lt;/h1&gt;

&lt;p&gt;React is a library that intentionally doesn't provide guidance about how to structure your project - and that can be really confusing for developers.&lt;/p&gt;

&lt;p&gt;While there are no hard and fast rules however, there are some best practices - so here are 10 tips about how to structure your React projects.&lt;/p&gt;

&lt;h1&gt;1.&lt;/h1&gt;

&lt;p&gt;First, and above all else: do what works for you and your team&lt;/p&gt;

&lt;p&gt;There is a lot of advice out there, and much of it conflicts&lt;/p&gt;

&lt;p&gt;Don't feel anxiety about not doing it "the right way"&lt;/p&gt;

&lt;p&gt;If it works for you and your team - then that is the "right way"&lt;/p&gt;

&lt;h1&gt;2.&lt;/h1&gt;

&lt;p&gt;That said:&lt;/p&gt;

&lt;p&gt;Keep all of your components and related code in a &lt;code&gt;src&lt;/code&gt; folder&lt;/p&gt;

&lt;p&gt;The other folder at the top level should be &lt;code&gt;public&lt;/code&gt; with static assets&lt;/p&gt;

&lt;p&gt;Images that you are going to import inside of components should be in &lt;code&gt;src&lt;/code&gt;, not &lt;code&gt;public&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--DKMonJmq--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/i/8na6df386ydy2wwzzwtc.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--DKMonJmq--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/i/8na6df386ydy2wwzzwtc.png" alt="Alt Text"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h1&gt;3.&lt;/h1&gt;

&lt;p&gt;Shared components go in a folder called &lt;code&gt;components&lt;/code&gt; or &lt;code&gt;shared&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;Inside of &lt;code&gt;components&lt;/code&gt;, group files by function; e.g., have a folder for &lt;code&gt;form&lt;/code&gt; components, one for &lt;code&gt;user&lt;/code&gt; components, etc&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--Vyx6mTbd--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/i/evhvk0cqvvkf3z03du4l.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--Vyx6mTbd--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/i/evhvk0cqvvkf3z03du4l.png" alt="Alt Text"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h1&gt;4.&lt;/h1&gt;

&lt;p&gt;Don't prematurely optimize though!&lt;/p&gt;

&lt;p&gt;At the start it's fine to just dump all the components into the same folder.  Clean it up later when you have a better idea of what your app looks like.&lt;/p&gt;

&lt;p&gt;That includes having multiple components per file... that's OK!  If you don't like it later - clean it up then.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--Q4lhzWTQ--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/i/3qzolx8bxjhs8gdlniwr.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--Q4lhzWTQ--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/i/3qzolx8bxjhs8gdlniwr.png" alt="Alt Text"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h1&gt;5.&lt;/h1&gt;

&lt;p&gt;Keep entire pages (route endpoints) in a folder called &lt;code&gt;pages&lt;/code&gt; or &lt;code&gt;screens&lt;/code&gt; (for React Native)&lt;/p&gt;

&lt;p&gt;Inside of that, group files per page in folders&lt;/p&gt;

&lt;p&gt;Name the main component either &lt;code&gt;index.js&lt;/code&gt; or &lt;code&gt;MyPageXYZ.js&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;(I like &lt;code&gt;MyPageXYZ.js&lt;/code&gt; because I don't like having 100 &lt;code&gt;index.js&lt;/code&gt; files - but it does make for more complicated imports)&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--EpVsb2j7--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/i/u3h29l6g8267wmj5rg1o.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--EpVsb2j7--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/i/u3h29l6g8267wmj5rg1o.png" alt="Alt Text"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h1&gt;6.&lt;/h1&gt;

&lt;p&gt;If a file's default export is a React component, capitalize that filename like the component itself&lt;/p&gt;

&lt;p&gt;That's a signal to other devs that a component is being exported&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--jaZzbrIm--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/i/h5ab4n6awhhri3q75219.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--jaZzbrIm--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/i/h5ab4n6awhhri3q75219.png" alt="Alt Text"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h1&gt;7.&lt;/h1&gt;

&lt;p&gt;Use absolute imports!&lt;/p&gt;

&lt;p&gt;Instead of:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight"&gt;&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="nx"&gt;MyComponent&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;../../components/pages/MyComponent&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;



&lt;p&gt;set up absolute imports and turn it into:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight"&gt;&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="nx"&gt;MyComponent&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;pages/MyComponent&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;



&lt;p&gt;Much nicer! 🎉&lt;/p&gt;

&lt;p&gt;Here's the docs:&lt;/p&gt;

&lt;p&gt;&lt;a href="https://create-react-app.dev/docs/importing-a-component/#absolute-imports"&gt;&lt;/a&gt;&lt;a href="https://create-react-app.dev/docs/importing-a-component/#absolute-imports"&gt;https://create-react-app.dev/docs/importing-a-component/#absolute-imports&lt;/a&gt;&lt;/p&gt;

&lt;h1&gt;8.&lt;/h1&gt;

&lt;p&gt;I like either css-in-js, or keeping css files next to the component they're used in&lt;/p&gt;

&lt;p&gt;Centralizing css files in a &lt;code&gt;stylesheets&lt;/code&gt; folder doesn't feel great to me anymore, but your mileage may vary - do what feels best&lt;/p&gt;

&lt;h1&gt;9.&lt;/h1&gt;

&lt;p&gt;Have a &lt;code&gt;lib&lt;/code&gt; or &lt;code&gt;utils&lt;/code&gt; folder for the random js helper functions that inevitably get created.&lt;/p&gt;

&lt;p&gt;If you don't start with one, those functions get peppered throughout your code and make it hard to share and find&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s---XpRp2Ql--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/i/iidm5zrv142ozg8b5kyj.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s---XpRp2Ql--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/i/iidm5zrv142ozg8b5kyj.png" alt="Alt Text"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h1&gt;10.&lt;/h1&gt;

&lt;p&gt;If using redux you can have separate &lt;code&gt;actions&lt;/code&gt;, &lt;code&gt;reducers&lt;/code&gt;, etc folders (that's how I do it)&lt;/p&gt;

&lt;p&gt;OR&lt;/p&gt;

&lt;p&gt;Keep it in a &lt;code&gt;redux&lt;/code&gt; folder (sometimes called the "ducks" pattern)&lt;/p&gt;

&lt;p&gt;Either way is fine&lt;/p&gt;

&lt;p&gt;Either way, I do highly recommend Redux toolkit though: &lt;a href="https://redux-toolkit.js.org/"&gt;&lt;/a&gt;&lt;a href="https://redux-toolkit.js.org/"&gt;https://redux-toolkit.js.org/&lt;/a&gt;&lt;/p&gt;

&lt;h1&gt;Finally&lt;/h1&gt;

&lt;p&gt;These are all just my opinions!  &lt;/p&gt;

&lt;p&gt;Others will probably come and disagree because they've found something that works better for them - and that's awesome;&lt;/p&gt;

&lt;p&gt;Find what works for you, and use that 🙌&lt;/p&gt;

&lt;h1&gt; &lt;/h1&gt;

&lt;p&gt;&lt;i&gt;Thanks for reading!  If you liked this post:&lt;/i&gt;&lt;/p&gt;

&lt;p&gt;🐦 You can find me on twitter: &lt;a href="https://twitter.com/chrisachard"&gt;@chrisachard&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;💌 Or sign up for my newsletter: &lt;a href="https://chrisachard.com/newsletter"&gt;&lt;/a&gt;&lt;a href="https://chrisachard.com/newsletter"&gt;https://chrisachard.com/newsletter&lt;/a&gt;&lt;/p&gt;

&lt;h1&gt; &lt;/h1&gt;

</description>
      <category>react</category>
      <category>webdev</category>
      <category>javascript</category>
    </item>
    <item>
      <title>How to Find Consulting Clients</title>
      <dc:creator>Chris Achard</dc:creator>
      <pubDate>Thu, 07 Nov 2019 13:24:30 +0000</pubDate>
      <link>https://forem.com/chrisachard/how-to-find-consulting-clients-2c19</link>
      <guid>https://forem.com/chrisachard/how-to-find-consulting-clients-2c19</guid>
      <description>&lt;p&gt;&lt;em&gt;This was originally posted on: &lt;a href="https://chrisachard.com/how-to-find-consulting-clients"&gt;https://chrisachard.com/how-to-find-consulting-clients&lt;/a&gt;&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;If you're considering a move into freelancing or consulting - the one question that's probably on your mind is: &lt;strong&gt;"How will I find clients?"&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;That's the one question I hear most often when I talk about consulting - and it's the one question I felt most vividly when I first started consulting independently.&lt;/p&gt;

&lt;p&gt;The good news is that there is a relatively straightforward path for finding new clients. Yes, it takes some time, and yes, it can be a bit of a grind - but you can get there.  Here's how.&lt;/p&gt;

&lt;h1&gt;
  
  
  Start before you're ready
&lt;/h1&gt;

&lt;p&gt;If you're like most consultants, the primary way you'll find most of your contracts is through people you already know.&lt;/p&gt;

&lt;p&gt;That sounds like unhelpful advice - but it really points to the type of activity you need to be doing if you think you want to do consulting at some point... you need to get to know people.&lt;/p&gt;

&lt;p&gt;That doesn't mean you should go "networking" - it means really getting out and getting to know people that fit in your area of expertise.&lt;/p&gt;

&lt;p&gt;The best way to do that is by finding local meetups in your area.&lt;/p&gt;

&lt;p&gt;If you're a software developer, find a local group for your language of choice, and go visit.  After a few meetings, offer to give a lightning talk.  Then a few months later give a full length talk.&lt;/p&gt;

&lt;p&gt;You'll grow a lot as a developer by doing those things - and you'll also get to know people who work for companies that could hire you down the line.&lt;/p&gt;

&lt;h1&gt;
  
  
  Visual proof that you know what you're talking about
&lt;/h1&gt;

&lt;p&gt;The next most important piece of the puzzle is some public proof that you know what you're doing... how can potential clients trust that you can get the work done?&lt;/p&gt;

&lt;p&gt;This could be a portfolio, or blog, or ebook (ebooks are magic for this) - but make sure you have &lt;em&gt;something&lt;/em&gt; to point to that shows you are an expert in your area.&lt;/p&gt;

&lt;p&gt;It seems like obvious advice - but you'd be surprised at how many consultants don't have a public demonstration that they're an expert... and then have trouble finding clients.&lt;/p&gt;

&lt;p&gt;Think about it from the client's perspective: &lt;strong&gt;how can you be trusted with their work?&lt;/strong&gt;&lt;/p&gt;

&lt;h1&gt;
  
  
  The mechanics of finding a client
&lt;/h1&gt;

&lt;p&gt;Ok - so you've gone to meetups, and you have a blog or ebook or youtube channel or podcast... now how do you actually get a client?&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;First:&lt;/strong&gt; Start mentioning that you're looking for clients.  &lt;/p&gt;

&lt;p&gt;Again - this sounds like obvious advice, but you need to actually do it!&lt;/p&gt;

&lt;p&gt;Go to the local people who you've met and say: &lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;"I'm starting to look for companies who need help with [X] - do you know of anyone I should talk to?"&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;The phrasing of that question is important.  If you just ask them if &lt;em&gt;their&lt;/em&gt; company is looking for consultants - then you're really limited their answers to just "yes" or "no".&lt;/p&gt;

&lt;p&gt;By asking if there is &lt;em&gt;anyone&lt;/em&gt; you should talk to though - they'll really think about other people they know as well.  &lt;/p&gt;

&lt;p&gt;Most of my clients in the past have not come directly from people I knew - but people who knew people I knew.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Second:&lt;/strong&gt; Be watchful for hidden opportunities&lt;/p&gt;

&lt;p&gt;Tech companies are continually looking for people to fill software development roles.  When people in your network post about their company looking to hire someone in your field of work - that's a great time to reach out and ask if they're ever interested in hiring contractors.&lt;/p&gt;

&lt;p&gt;The answer might be "no" or "not right now" - but you will have at least planted a seed in their mind that you're someone who is looking for clients - and that will often pay off months, or even years down the line.&lt;/p&gt;

&lt;h1&gt;
  
  
  Subcontracting
&lt;/h1&gt;

&lt;p&gt;Another method that works well is to be a sub-contractor for another consulting company.  &lt;/p&gt;

&lt;p&gt;You won't make quite the same money that you could if you went direct to clients - but you also don't have the same hassles that you might if you were in charge of the client relationship; so there are some tradeoffs there.&lt;/p&gt;

&lt;p&gt;To do this, find a consulting company (start small: 5 - 10 person companies are often the most open to these arrangements), and just send an email to ask:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;"I'm a consultant for [X] and see that you do that as well.  Do you ever have projects that you need help with?"&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;Many small software consultancies I know about have more work than they can handle at one time or another - so you'll be surprised at how often this type of email will lead to work.&lt;/p&gt;

&lt;h1&gt;
  
  
  How to get a client quickly
&lt;/h1&gt;

&lt;p&gt;Sometimes though - you just can't wait... you need a client quickly.&lt;/p&gt;

&lt;p&gt;In those cases, it can be tempting to go to one of the few big freelancing sites out there and look for work - but &lt;strong&gt;don't do that!&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Instead, here's what I recommend:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;&lt;p&gt;Look on tech job boards for jobs that you know you could do, and that have emails of the people who are actually looking to hire (not HR).&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Reach out to those people directly and say: &lt;/p&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;blockquote&gt;
&lt;p&gt;"I'm not looking for a full time position, but would you be open to a contractor?"&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;You'll get a lot of people who don't respond, and a fair number of people who say "no" - but I'm often surprised by how many are interested!&lt;/p&gt;

&lt;p&gt;Smaller companies are often more open to these arrangements (less red tape), and it's best if you can get the direct email of the person who leads the technical team - so look for those situations especially.&lt;/p&gt;

&lt;p&gt;Also - if you do get a "no", you can always follow up with:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;"No problem - do you know anyone else I should talk to?"&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;The tech world is fairly small - and so don't waste an opportunity to ask for introductions.&lt;/p&gt;

&lt;h1&gt;
  
  
  You only need a few
&lt;/h1&gt;

&lt;p&gt;Independent consulting sounds big and scary at first, but remember - you only really need a few clients to have a really good year.  &lt;/p&gt;

&lt;p&gt;This isn't a high-volume sales game; but rather it's more about getting to know people and showing that you can do the work&lt;/p&gt;

&lt;p&gt;That doesn't mean it's easy!&lt;/p&gt;

&lt;p&gt;...but right now the world is clamoring for more and more software developers.&lt;/p&gt;

&lt;p&gt;So don't get discouraged by the "No"s... you only need a few "yes"es to make it all worth it.&lt;/p&gt;

&lt;p&gt; &lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Like this post?&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Find more on twitter: &lt;a href="https://twitter.com/chrisachard"&gt;@chrisachard&lt;/a&gt;&lt;br&gt;
Or join the newsletter! 📬 &lt;a href="https://chrisachard.com/newsletter"&gt;https://chrisachard.com/newsletter&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Thanks for reading!&lt;/p&gt;

</description>
      <category>career</category>
      <category>motivation</category>
      <category>consulting</category>
    </item>
    <item>
      <title>Fear Driven Development</title>
      <dc:creator>Chris Achard</dc:creator>
      <pubDate>Thu, 31 Oct 2019 13:13:49 +0000</pubDate>
      <link>https://forem.com/chrisachard/fear-driven-development-57d9</link>
      <guid>https://forem.com/chrisachard/fear-driven-development-57d9</guid>
      <description>&lt;p&gt;It's Halloween today in the US!&lt;/p&gt;

&lt;p&gt;Halloween is a day where kids can dress up as something scary and go out at night to knock on the doors of strangers.&lt;/p&gt;

&lt;p&gt;That's a lot of things to be scared of!  Scary costumes, out in the dark, and talking to strangers.  But what is the reward for confronting those fears?&lt;/p&gt;

&lt;p&gt;🍫🍭🍬 &lt;strong&gt;CANDY&lt;/strong&gt; 🍬🍭🍫&lt;/p&gt;

&lt;p&gt;Pounds and pounds of glorious candy...&lt;/p&gt;

&lt;h1&gt;
  
  
  Fear in Software Development
&lt;/h1&gt;

&lt;p&gt;While coding, there is a similar list of fears we might have.  Do any of these thoughts sound familiar?&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;"This block of code looks gnarly; let's ignore it for now"&lt;/p&gt;

&lt;p&gt;"That library seems confusing; I'll figure it out later"&lt;/p&gt;

&lt;p&gt;"This feature seems hard... I'll skip it and come back tomorrow"&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;I have those thoughts &lt;strong&gt;all the time&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;Recently though, I realized how it holds me back to put off the difficult tasks until &lt;em&gt;"later"&lt;/em&gt;.&lt;/p&gt;

&lt;p&gt;Those tasks sit on my todo list, staring me in the face, and I know that I'm going to have to figure them out at some point... &lt;/p&gt;

&lt;h1&gt;
  
  
  Embracing Your Fears
&lt;/h1&gt;

&lt;p&gt;So what happens when I finally do get around to tackling the very difficult problems?&lt;/p&gt;

&lt;p&gt;They usually aren't so bad after all.&lt;/p&gt;

&lt;p&gt;It happened to me recently with Stripe:&lt;/p&gt;

&lt;p&gt;I hadn't ever done a full Stripe integration front-to-back by myself.  I've worked with it before, but had never actually done the setup and initial integration myself.&lt;/p&gt;

&lt;p&gt;The tasks &lt;strong&gt;seemed&lt;/strong&gt; really difficult; my thought process was something like this:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;"Charging people &lt;em&gt;real&lt;/em&gt; money? Sounds pretty hard"&lt;/li&gt;
&lt;li&gt;"What if I do it wrong? I don't want to make a huge mistake when it involves charging money"&lt;/li&gt;
&lt;li&gt;"There are a &lt;strong&gt;ton&lt;/strong&gt; of docs, and so many ways to do it... where do I start?"&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;All the while, the bullet point of "Integrate Stripe" was on my todo list - just staring at me 👀&lt;/p&gt;

&lt;p&gt;Eventually I just had to get it done, so I got started... And you know what?  It really wasn't all that hard after all.&lt;/p&gt;

&lt;p&gt;It was kind of tricky, yes; and it did take most of a day to feel like I really understood what I was doing; but after that? It became &lt;em&gt;easy&lt;/em&gt;.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Difficult tasks have a way of becoming easy after just a little bit of learning.&lt;/strong&gt;&lt;/p&gt;

&lt;h1&gt;
  
  
  Fear Driven Development
&lt;/h1&gt;

&lt;p&gt;&lt;em&gt;So I'm trying something new now.&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;Whenever I have a really scary task on my list: I'm going to tackle that one &lt;strong&gt;FIRST&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;We don't need to let our scary todo items paralyze us.  We get to choose our response to them - and I choose knowledge and understanding.&lt;/p&gt;

&lt;p&gt;Big gnarly todo items are often not so big and scary once you break them down a bit - but it's the &lt;em&gt;fear&lt;/em&gt; of those items that can paralyze your development and slow you down.&lt;/p&gt;

&lt;h1&gt;
  
  
  Reaping the Rewards
&lt;/h1&gt;

&lt;p&gt;So what's the reward for tackling the unknown?&lt;/p&gt;

&lt;p&gt;🍫🍭🍬 &lt;strong&gt;GLORIOUS CANDY&lt;/strong&gt; 🍬🍭🍫&lt;/p&gt;

&lt;p&gt;&lt;em&gt;oh, that's Halloween&lt;/em&gt;.  &lt;/p&gt;

&lt;p&gt;I mean:&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Knowledge and peace&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;It feels &lt;em&gt;really&lt;/em&gt; good to tackle a big problem.  The build-up feels awful (not knowing where to start; not knowing how long it will take) - but the only solution is to get started.&lt;/p&gt;

&lt;p&gt;So next time: instead of procrastinating on the big, scary thing I have on my todo list... I'm going to &lt;strong&gt;start&lt;/strong&gt; with that one.&lt;/p&gt;

&lt;p&gt; &lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Like this post?&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Find more on twitter: &lt;a href="https://twitter.com/chrisachard"&gt;@chrisachard&lt;/a&gt;&lt;br&gt;
Or join the newsletter: 📬 &lt;a href="https://chrisachard.com/newsletter/"&gt;https://chrisachard.com/newsletter/&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Thanks for reading!&lt;/p&gt;

</description>
      <category>productivity</category>
      <category>motivation</category>
      <category>programming</category>
    </item>
    <item>
      <title>DNS Record Crash Course for Web Developers</title>
      <dc:creator>Chris Achard</dc:creator>
      <pubDate>Tue, 29 Oct 2019 11:19:50 +0000</pubDate>
      <link>https://forem.com/chrisachard/dns-record-crash-course-for-web-developers-35hn</link>
      <guid>https://forem.com/chrisachard/dns-record-crash-course-for-web-developers-35hn</guid>
      <description>&lt;p&gt;&lt;em&gt;This was originally posted as a twitter thread: &lt;a href="https://twitter.com/chrisachard/status/1188870256971915265" rel="noopener noreferrer"&gt;https://twitter.com/chrisachard/status/1188870256971915265&lt;/a&gt;&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;Confused by DNS Records? A, CNAME, ALIAS...&lt;/p&gt;

&lt;p&gt;Me too 😬 &lt;/p&gt;

&lt;p&gt;Let's change that! (cheatsheet at the end)&lt;/p&gt;

&lt;p&gt;🔥 DNS Record crash course for web developers 👇&lt;/p&gt;

&lt;h1&gt;
  
  
  1.
&lt;/h1&gt;

&lt;p&gt;To get to &lt;code&gt;www.example.com&lt;/code&gt;, your computer needs to know where on the Internet that server is&lt;/p&gt;

&lt;p&gt;That means: it has to know what IP address to talk to&lt;/p&gt;

&lt;p&gt;The way it finds out is the Domain Name System (DNS)&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%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fo60vlffckjreoux3q8p3.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%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fo60vlffckjreoux3q8p3.png" alt="DNS diagram"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h1&gt;
  
  
  2.
&lt;/h1&gt;

&lt;p&gt;When you register a domain, you can set many types of DNS Records&lt;/p&gt;

&lt;p&gt;Each record has a Type, a Host, and a Value&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;"Types" are predefined&lt;/li&gt;
&lt;li&gt;"Host" represents the root (&lt;code&gt;@&lt;/code&gt;) or a subdomain (&lt;code&gt;www&lt;/code&gt;)&lt;/li&gt;
&lt;li&gt;"Value" is an IP or web address, or other value&lt;/li&gt;
&lt;/ul&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%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fpmhvmi1bfavxw65h37zh.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%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fpmhvmi1bfavxw65h37zh.png" alt="DNS records type, host and value"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h1&gt;
  
  
  3.
&lt;/h1&gt;

&lt;p&gt;The &lt;code&gt;A&lt;/code&gt; record maps a subdomain to an IPv4 address&lt;/p&gt;

&lt;p&gt;This is most commonly used at the root, so it tells your browser where &lt;code&gt;example.com&lt;/code&gt; lives&lt;/p&gt;

&lt;p&gt;The &lt;code&gt;AAAA&lt;/code&gt; record does the same for IPv6&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%2Fthepracticaldev.s3.amazonaws.com%2Fi%2F46bx3zbixp0ul68iukvb.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%2Fthepracticaldev.s3.amazonaws.com%2Fi%2F46bx3zbixp0ul68iukvb.png" alt="DNS A records"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h1&gt;
  
  
  4.
&lt;/h1&gt;

&lt;p&gt;&lt;code&gt;CNAME&lt;/code&gt; maps a subdomain to another domain name&lt;/p&gt;

&lt;p&gt;This can be another subdomain on the same site (like forwarding www to the root)&lt;/p&gt;

&lt;p&gt;or another domain like heroku - where your app lives&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%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fwgcbnpn19mzjs635ntdg.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%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fwgcbnpn19mzjs635ntdg.png" alt="CNAME DNS Record"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h1&gt;
  
  
  5.
&lt;/h1&gt;

&lt;p&gt;But there's a problem with &lt;code&gt;CNAME&lt;/code&gt;!&lt;/p&gt;

&lt;p&gt;Once you define a &lt;code&gt;CNAME&lt;/code&gt; record for a subdomain (host), you CAN'T DEFINE another record for that same subdomain&lt;/p&gt;

&lt;p&gt;Because of this, you can't use &lt;code&gt;CNAME&lt;/code&gt; at the root level (where you need other records to exist)&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%2Fthepracticaldev.s3.amazonaws.com%2Fi%2F5vecxhflnsvemjzfpmna.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%2Fthepracticaldev.s3.amazonaws.com%2Fi%2F5vecxhflnsvemjzfpmna.png" alt="Don't use CNAME at the root"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h1&gt;
  
  
  6.
&lt;/h1&gt;

&lt;p&gt;To fix that, &lt;code&gt;ALIAS&lt;/code&gt; is used (sometimes &lt;code&gt;ANAME&lt;/code&gt;)&lt;/p&gt;

&lt;p&gt;&lt;code&gt;ALIAS&lt;/code&gt; is like &lt;code&gt;CNAME&lt;/code&gt;, but it's a non-standard dns type&lt;/p&gt;

&lt;p&gt;So you can use &lt;code&gt;ALIAS&lt;/code&gt; to forward your root domain (&lt;code&gt;example.com&lt;/code&gt;) to your app's server (&lt;code&gt;example.herokudns.com&lt;/code&gt;)&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%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fcvyrzccpi5pfbdaq3vu3.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%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fcvyrzccpi5pfbdaq3vu3.png" alt="Use ALIAS at the root of the domain"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h1&gt;
  
  
  7.
&lt;/h1&gt;

&lt;p&gt;That lets you put other records at the root, like:&lt;/p&gt;

&lt;p&gt;&lt;code&gt;TXT&lt;/code&gt; records, which provide extra info to any computer reading the DNS record&lt;/p&gt;

&lt;p&gt;&lt;code&gt;TXT&lt;/code&gt; records are often used to prove you own a domain - because only the domain owner can set a DNS record.&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%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fsqkjftx3dradhs6rc69m.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%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fsqkjftx3dradhs6rc69m.png" alt="TXT Record information"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h1&gt;
  
  
  8.
&lt;/h1&gt;

&lt;p&gt;Or:&lt;/p&gt;

&lt;p&gt;&lt;code&gt;MX&lt;/code&gt; records (Mail eXchange), which you use to specify another server that handles your email (like google)&lt;/p&gt;

&lt;p&gt;&lt;code&gt;MX&lt;/code&gt; records are unique because you can set multiple servers that are each given a "priority"&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%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fovxdcaxh6qssqhrmzuyy.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%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fovxdcaxh6qssqhrmzuyy.png" alt="MX Records"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h1&gt;
  
  
  9.
&lt;/h1&gt;

&lt;p&gt;There are many other record types, but those are the ones you'll most often set yourself.&lt;/p&gt;

&lt;p&gt;For each record, you also specify a Time To Live (TTL)&lt;/p&gt;

&lt;p&gt;This tells DNS servers how long to cache your DNS values&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%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fyp5ou5rbusvgh2dniyt2.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%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fyp5ou5rbusvgh2dniyt2.png" alt="TTL determines cache"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h1&gt;
  
  
  10.
&lt;/h1&gt;

&lt;p&gt;TTL is why it can take some time for your new domain records to "propagate"&lt;/p&gt;

&lt;p&gt;DNS servers, your ISP, and even your own computer can cache DNS records, serving up the "old" values until the TTL runs out&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%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fjk9x11hml6s3f7qrnxzj.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%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fjk9x11hml6s3f7qrnxzj.png" alt="DNS Cache"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h1&gt;
  
  
  Cheatsheet
&lt;/h1&gt;

&lt;p&gt;Hopefully that made DNS a bit less confusing for when you set up your next domain!&lt;/p&gt;

&lt;p&gt;To put it all together, here's a PDF cheatsheet of this crash course: &lt;a href="https://chrisachard.com/cheatsheets/dns-cheatsheet.pdf" rel="noopener noreferrer"&gt;https://chrisachard.com/cheatsheets/dns-cheatsheet.pdf&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;🎉&lt;/p&gt;

&lt;p&gt; &lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Like this Post?&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;You can find more on twitter: &lt;a href="https://twitter.com/chrisachard" rel="noopener noreferrer"&gt;@chrisachard&lt;/a&gt;&lt;br&gt;
Or join the newsletter 📬 &lt;a href="https://chrisachard.com/newsletter/" rel="noopener noreferrer"&gt;https://chrisachard.com/newsletter/&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Thanks for reading!&lt;/p&gt;

</description>
      <category>webdev</category>
      <category>devops</category>
      <category>dns</category>
    </item>
    <item>
      <title>What is your favorite editor and why?</title>
      <dc:creator>Chris Achard</dc:creator>
      <pubDate>Tue, 22 Oct 2019 19:50:49 +0000</pubDate>
      <link>https://forem.com/chrisachard/what-is-your-favorite-editor-and-why-5e1i</link>
      <guid>https://forem.com/chrisachard/what-is-your-favorite-editor-and-why-5e1i</guid>
      <description>&lt;p&gt;I used to use TextMate, but switched to Sublime Text when they stopped supporting TextMate 1 (many years ago), and have gotten really fast with Sublime.&lt;/p&gt;

&lt;p&gt;Recently though I've played around with VS Code and really like it (because of how customizable it is), but I still find myself opening Sublime more.&lt;/p&gt;

&lt;p&gt;So: without starting any editor "wars", I was just curious: &lt;strong&gt;what is your favorite editor right now and why?&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;If you'd like to give more context, I'd also love to know: &lt;em&gt;What is your favorite plugin/extension for that editor?&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;For Sublime, one fun one is "Emoji" (so you can insert emojis with just a few keystrokes): &lt;a href="https://packagecontrol.io/packages/Emoji"&gt;https://packagecontrol.io/packages/Emoji&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;And for VS Code, an underrated one I think is "Custom CSS", which lets you fully customize the VSCode experience by writing custom css: &lt;a href="https://github.com/be5invis/vscode-custom-css"&gt;https://github.com/be5invis/vscode-custom-css&lt;/a&gt;&lt;/p&gt;

</description>
      <category>discuss</category>
    </item>
    <item>
      <title>Music to Listen to While Coding</title>
      <dc:creator>Chris Achard</dc:creator>
      <pubDate>Tue, 15 Oct 2019 21:08:50 +0000</pubDate>
      <link>https://forem.com/chrisachard/music-to-listen-to-while-coding-3pn1</link>
      <guid>https://forem.com/chrisachard/music-to-listen-to-while-coding-3pn1</guid>
      <description>&lt;p&gt;&lt;em&gt;This was originally published on: &lt;a href="https://chrisachard.com/music-to-listen-to-while-coding"&gt;https://chrisachard.com/music-to-listen-to-while-coding&lt;/a&gt;&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;Music is a very personal thing, so there's no "one size fits all" for music that will put you in a good mindset to tackle a complicated coding challenge.&lt;/p&gt;

&lt;h1&gt;
  
  
  Music Guidelines
&lt;/h1&gt;

&lt;p&gt;With that said, here are the guidelines I follow when choosing music for a coding session:&lt;/p&gt;

&lt;h2&gt;
  
  
  1. Limited Vocals
&lt;/h2&gt;

&lt;p&gt;If there is a vocal track in music, my brain tends to focus on the words being sung - so when I want to get deep into a coding problem, I'll select music that doesn't have any vocals.  &lt;/p&gt;

&lt;p&gt;That way, I can focus on the work, and not on the music - the music will just fade into the background.&lt;/p&gt;

&lt;h2&gt;
  
  
  2. Familiar Music
&lt;/h2&gt;

&lt;p&gt;For the same reason, I tend to select the same music (or type of music).  &lt;/p&gt;

&lt;p&gt;If I'm listening to music that's new to me, then I will focus on the music instead of the coding - so by selecting music I've heard many times before, my brain can separate the music from the coding.&lt;/p&gt;

&lt;h2&gt;
  
  
  3. Good Beat and Pace
&lt;/h2&gt;

&lt;p&gt;If music is too slow or ethereal, then it signals my brain to move more slowly.&lt;/p&gt;

&lt;p&gt;If music is too fast or intense, then I feel rushed or stressed.&lt;/p&gt;

&lt;p&gt;Neither condition is good for deep work!  Instead, I focus on finding music that has a consistent (but not intense) forward motion - pushing me to keep working.&lt;/p&gt;

&lt;h1&gt;
  
  
  Specific Music Choices
&lt;/h1&gt;

&lt;p&gt;So: what types of music fit those criteria?&lt;/p&gt;

&lt;h2&gt;
  
  
  1. Movie Soundtracks
&lt;/h2&gt;

&lt;p&gt;I love movie soundtracks of "big", epic movies - they are often orchestral (so limited vocals), and build in a really unique and positive way.&lt;/p&gt;

&lt;p&gt;Soundtracks will also be a few hours long, so there's plenty of consistent music for a nice long coding session.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Suggestions&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Interstellar Soundtrack: &lt;a href="https://www.youtube.com/watch?v=DY8nqIfsQkU"&gt;https://www.youtube.com/watch?v=DY8nqIfsQkU&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Lord of the Rings Soundtrack: &lt;a href="https://www.youtube.com/watch?v=_SBQvd6vY9s"&gt;https://www.youtube.com/watch?v=_SBQvd6vY9s&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  2. Video Game Soundtracks
&lt;/h2&gt;

&lt;p&gt;Keeping in the soundtrack theme is an often overlooked genre: video games!  &lt;/p&gt;

&lt;p&gt;Video game soundtracks are great because you know they were specifically designed to keep players "in the game" - so they're repetitive, and focused on a mission; that makes them great for coding!&lt;/p&gt;

&lt;p&gt;I recommend picking video games that you're familiar with, but here are a few that I listen to:&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Suggestions&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Final Fantasy Soundtrack(s): &lt;a href="https://www.youtube.com/watch?v=7Iweue-OcMo"&gt;https://www.youtube.com/watch?v=7Iweue-OcMo&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Outpost 2 Soundtrack: &lt;a href="https://www.youtube.com/watch?v=6ilJcs7JL4M&amp;amp;list=PL0G3yY9NMFWcCdapK2ub5-XVgftyDVE3g"&gt;https://www.youtube.com/watch?v=6ilJcs7JL4M&amp;amp;list=PL0G3yY9NMFWcCdapK2ub5-XVgftyDVE3g&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  3. Electronic Study Music
&lt;/h2&gt;

&lt;p&gt;Not all EDM is good for coding, but there's a specific sub-genre of electronic music that is specifically designed for keeping you "in the zone".&lt;/p&gt;

&lt;p&gt;It often goes by the name "study music", (so you'd expect it to be good for studying!) and I really like it for coding as well.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Suggestions&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Electronic Music for Studying: &lt;a href="https://www.youtube.com/results?search_query=study+edm"&gt;https://www.youtube.com/results?search_query=study+edm&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  4. Orchestral Music
&lt;/h2&gt;

&lt;p&gt;If you're a fan of classical music, then there are endless options to choose from here.  &lt;/p&gt;

&lt;p&gt;I like to listen to entire concerts, because there are usually a variety of songs played (different tempos, etc), which can be a nice way to break up the day.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Suggestions&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Beethoven 9 &lt;a href="https://www.youtube.com/watch?v=rOjHhS5MtvA"&gt;https://www.youtube.com/watch?v=rOjHhS5MtvA&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  5. Lounge / Elevator Music
&lt;/h2&gt;

&lt;p&gt;This is music &lt;em&gt;designed&lt;/em&gt; to be played in the background!  &lt;/p&gt;

&lt;p&gt;There are endless hours of lounge music available, and they all create a nice backdrop for getting real work done.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Suggestions&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Relaxing Jazz: &lt;a href="https://www.youtube.com/watch?v=rOjHhS5MtvA"&gt;https://www.youtube.com/watch?v=rOjHhS5MtvA&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Ambient Chillout: &lt;a href="https://www.youtube.com/watch?v=r-tEQzU3fwY"&gt;https://www.youtube.com/watch?v=r-tEQzU3fwY&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  6. Coffee Shop Background
&lt;/h2&gt;

&lt;p&gt;Sometimes, you just want to feel like you're not in an office :)  That's where coffee shop background noise can help!&lt;/p&gt;

&lt;p&gt;There are hours and hours of coffee shop background tracks online, and it can be a nice way to feel surrounded without any people actually being around.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Suggestions&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Coffee Shop Sounds: &lt;a href="https://www.youtube.com/results?search_query=coffee+shop+sounds"&gt;https://www.youtube.com/results?search_query=coffee+shop+sounds&lt;/a&gt;&lt;/p&gt;

&lt;h1&gt;
  
  
  Why Listen to Music
&lt;/h1&gt;

&lt;p&gt;I don't always listen to music, but when I do, I want it to &lt;em&gt;get me in the zone&lt;/em&gt; - and not to distract from the work I'm doing.&lt;/p&gt;

&lt;p&gt;Remember: there are no rules here!  Whatever works for you, works for you; but hopefully this post has given you some new ideas about what to listen to the next time you need some background music.&lt;/p&gt;

&lt;p&gt;Happy listening!&lt;/p&gt;

&lt;p&gt; &lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Like this post?&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Find more on twitter: &lt;a href="https://twitter.com/chrisachard"&gt;@chrisachard&lt;/a&gt;&lt;br&gt;
Or join the newsletter! &lt;a href="https://chrisachard.com/newsletter/"&gt;https://chrisachard.com/newsletter/&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Thanks for reading!&lt;/p&gt;

</description>
      <category>productivity</category>
      <category>programming</category>
      <category>music</category>
    </item>
    <item>
      <title>Intro to Regex for Web Developers</title>
      <dc:creator>Chris Achard</dc:creator>
      <pubDate>Tue, 08 Oct 2019 17:23:11 +0000</pubDate>
      <link>https://forem.com/chrisachard/intro-to-regex-for-web-developers-2fj4</link>
      <guid>https://forem.com/chrisachard/intro-to-regex-for-web-developers-2fj4</guid>
      <description>&lt;p&gt;&lt;em&gt;This was originally posted as a twitter thread: &lt;a href="https://twitter.com/chrisachard/status/1181583499112976384" rel="noopener noreferrer"&gt;https://twitter.com/chrisachard/status/1181583499112976384&lt;/a&gt;&lt;/em&gt;&lt;/p&gt;

&lt;h1&gt;
  
  
  1.
&lt;/h1&gt;

&lt;p&gt;Regular expressions find parts of a string that match a pattern&lt;/p&gt;

&lt;p&gt;In JavaScript they're created in between forward slashes //, or with &lt;code&gt;new RegExp()&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;and then used in methods like &lt;code&gt;match&lt;/code&gt;, &lt;code&gt;test&lt;/code&gt;, or &lt;code&gt;replace&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;You can define the regex beforehand, or directly when calling the method&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%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fdxy7culkg79az2jxelbb.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%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fdxy7culkg79az2jxelbb.png" alt="new regex"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h1&gt;
  
  
  2.
&lt;/h1&gt;

&lt;p&gt;Match individual characters one at a time,&lt;/p&gt;

&lt;p&gt;or put multiple characters in square brackets [] to capture any that match&lt;/p&gt;

&lt;p&gt;Capture a range of characters with a hyphen -&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%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fe57n2aafcvfybbjnxnq2.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%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fe57n2aafcvfybbjnxnq2.png" alt="square brackets and hyphen"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h1&gt;
  
  
  3.
&lt;/h1&gt;

&lt;p&gt;Add optional flags to the end of a regex to modify how the matcher works.&lt;/p&gt;

&lt;p&gt;In JavaScript, these flags are:&lt;/p&gt;

&lt;p&gt;i = case insensitive&lt;br&gt;
m = multi line matching&lt;br&gt;
g = global match (find all, instead of find one)&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%2Fthepracticaldev.s3.amazonaws.com%2Fi%2F0ahq9l1nkhf34e21er9y.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%2Fthepracticaldev.s3.amazonaws.com%2Fi%2F0ahq9l1nkhf34e21er9y.png" alt="regex flag modifiers"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h1&gt;
  
  
  4.
&lt;/h1&gt;

&lt;p&gt;Using a caret ^ at the start means "start of string"&lt;/p&gt;

&lt;p&gt;Using a dollar sign $ at the end means "end of string"&lt;/p&gt;

&lt;p&gt;Start putting groups of matches together to match longer strings&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%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fwjtzi9wdegzd2zw5y0f1.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%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fwjtzi9wdegzd2zw5y0f1.png" alt="caret dollar sign, group matches together"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h1&gt;
  
  
  5.
&lt;/h1&gt;

&lt;p&gt;Use wildcards and special escaped characters to match larger classes of characters&lt;/p&gt;

&lt;p&gt;. = any character except line break&lt;/p&gt;

&lt;p&gt;\d = digit&lt;br&gt;
\D = NOT a digit&lt;/p&gt;

&lt;p&gt;\s = white space&lt;br&gt;
\S = any NON white space&lt;/p&gt;

&lt;p&gt;\n new line&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%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fyc1g45ohkunt2nr0az0x.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%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fyc1g45ohkunt2nr0az0x.png" alt="wildcards"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h1&gt;
  
  
  6.
&lt;/h1&gt;

&lt;p&gt;Match only certain counts of matched characters or groups with &lt;em&gt;quantifiers&lt;/em&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;= zero or more&lt;/li&gt;
&lt;li&gt;= one more more
? = 0 or 1
{3} = exactly 3 times
{2, 4} = two, three, or four times
{2,} = two or more times&lt;/li&gt;
&lt;/ul&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%2Fthepracticaldev.s3.amazonaws.com%2Fi%2F4ej8dmrpgobmscgzjkch.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%2Fthepracticaldev.s3.amazonaws.com%2Fi%2F4ej8dmrpgobmscgzjkch.png" alt="quantifiers"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h1&gt;
  
  
  7.
&lt;/h1&gt;

&lt;p&gt;Use parens () to capture in a group&lt;/p&gt;

&lt;p&gt;&lt;code&gt;match&lt;/code&gt; will return the full match plus the groups, unless you use the &lt;code&gt;g&lt;/code&gt; flag&lt;/p&gt;

&lt;p&gt;Use the pipe operator | inside of parens () to specify what that group matches&lt;/p&gt;

&lt;p&gt;| = or&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%2Fthepracticaldev.s3.amazonaws.com%2Fi%2F0mwb6vtlj5bq2eki670x.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%2Fthepracticaldev.s3.amazonaws.com%2Fi%2F0mwb6vtlj5bq2eki670x.png" alt="parens to capture group"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h1&gt;
  
  
  8.
&lt;/h1&gt;

&lt;p&gt;To match special characters, escape them with a backslash \&lt;/p&gt;

&lt;p&gt;Special characters in JS regex are: ^ $ \ . * + ? ( ) [ ] { } |&lt;/p&gt;

&lt;p&gt;So to match an asterisks, you'd use:&lt;/p&gt;

&lt;p&gt;\*&lt;/p&gt;

&lt;p&gt;Instead of just * &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%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Faes2oqz8nmcnh42jwji9.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%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Faes2oqz8nmcnh42jwji9.png" alt="special characters"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h1&gt;
  
  
  9.
&lt;/h1&gt;

&lt;p&gt;To match anything BUT a certain character, use a caret ^ inside of square brackets&lt;/p&gt;

&lt;p&gt;This means ^ has two meanings, which can be confusing.  &lt;/p&gt;

&lt;p&gt;It means both "start of string" when it is at the front of a regex, and "not this character" when used inside of square brackets.&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%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fn92rltfmma8oywdnayzv.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%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fn92rltfmma8oywdnayzv.png" alt="caret to mean NOT"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h1&gt;
  
  
  10.
&lt;/h1&gt;

&lt;p&gt;Regexs can be used to find and match all sort of things, from urls to filenames&lt;/p&gt;

&lt;p&gt;HOWEVER! be careful if you try to use regexs for really complex tasks, such as parsing emails (which get really confusing, really fast), or HTML (which is not a regular language, and so can't be fully parsed by a regular expression)&lt;/p&gt;

&lt;p&gt;There is (of course) much more to regex like lazy vs greedy, lookahead, and capturing&lt;/p&gt;

&lt;p&gt;but most of what web developers want to do with regular expressions can use just these base building blocks.&lt;/p&gt;

&lt;p&gt;I'm already writing a follow up post with a bunch of real world regex use cases 🎉&lt;/p&gt;

&lt;p&gt; &lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Like this post?&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Find more on twitter: &lt;a href="https://twitter.com/chrisachard" rel="noopener noreferrer"&gt;@chrisachard&lt;/a&gt;&lt;br&gt;
Or join the newsletter 📬 &lt;a href="https://chrisachard.com/newsletter/" rel="noopener noreferrer"&gt;https://chrisachard.com/newsletter/&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Thanks for reading!&lt;/p&gt;

</description>
      <category>webdev</category>
      <category>javascript</category>
      <category>beginners</category>
    </item>
    <item>
      <title>Redux Crash Course with Hooks 🎣</title>
      <dc:creator>Chris Achard</dc:creator>
      <pubDate>Wed, 02 Oct 2019 12:01:45 +0000</pubDate>
      <link>https://forem.com/chrisachard/redux-crash-course-with-hooks-a54</link>
      <guid>https://forem.com/chrisachard/redux-crash-course-with-hooks-a54</guid>
      <description>&lt;p&gt;&lt;em&gt;This was originally posted as a twitter thread: &lt;a href="https://twitter.com/chrisachard/status/1179015849459507200" rel="noopener noreferrer"&gt;https://twitter.com/chrisachard/status/1179015849459507200&lt;/a&gt;&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;Does Redux have you confused?&lt;/p&gt;

&lt;p&gt;It can be simpler with the new Redux hooks.&lt;/p&gt;

&lt;p&gt;🔥Here's a crash course into Redux, and how you can use it with React function components:&lt;/p&gt;

&lt;h1&gt;
  
  
  1.
&lt;/h1&gt;

&lt;p&gt;Redux gives you a central place to put your state (data) for JavaScript apps&lt;/p&gt;

&lt;p&gt;It's most often used with React (via react-redux)&lt;/p&gt;

&lt;p&gt;This lets you access or change your state from ANY component in your tree&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%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fq0v61a2us4iixkpoyno9.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%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fq0v61a2us4iixkpoyno9.png" alt="Redux store"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h1&gt;
  
  
  2.
&lt;/h1&gt;

&lt;p&gt;Your state lives in a central Redux store&lt;/p&gt;

&lt;p&gt;That store is created with a function called a reducer&lt;/p&gt;

&lt;p&gt;A reducer takes in a state and an action,&lt;br&gt;
and returns the same or a NEW state&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%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fsb0chu53pbi5nz7zur07.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%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fsb0chu53pbi5nz7zur07.png" alt="Central store reducer"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h1&gt;
  
  
  3.
&lt;/h1&gt;

&lt;p&gt;The store is given to your app using the &lt;code&gt;Provider&lt;/code&gt; from react-redux&lt;/p&gt;

&lt;p&gt;Use the provider to wrap your entire app, so that any component in your app can access the store&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%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fi1z8b0ma7b8zjd34axk2.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%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fi1z8b0ma7b8zjd34axk2.png" alt="Redux Provider"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h1&gt;
  
  
  4.
&lt;/h1&gt;

&lt;p&gt;To get data out of the store, use the &lt;code&gt;useSelector&lt;/code&gt; hook from react-redux&lt;/p&gt;

&lt;p&gt;&lt;code&gt;selector&lt;/code&gt; is just a fancy word for: "function that gets data from the store"&lt;/p&gt;

&lt;p&gt;useSelector takes a callback, which gets the entire redux state, and you just pick out what you need for that component&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%2Fthepracticaldev.s3.amazonaws.com%2Fi%2F2z4der2vvau8de8vhre0.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%2Fthepracticaldev.s3.amazonaws.com%2Fi%2F2z4der2vvau8de8vhre0.png" alt="useSelector"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h1&gt;
  
  
  5.
&lt;/h1&gt;

&lt;p&gt;Actions are plain JavaScript objects&lt;/p&gt;

&lt;p&gt;All actions should have a 'type' key&lt;/p&gt;

&lt;p&gt;They may also have additional keys (parameters)&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%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fsk1hqh1qknshm1pv0e4l.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%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fsk1hqh1qknshm1pv0e4l.png" alt="Actions have a type key"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h1&gt;
  
  
  6.
&lt;/h1&gt;

&lt;p&gt;Actions are not "called", but are "dispatched" to the reducers&lt;/p&gt;

&lt;p&gt;The action &lt;code&gt;type&lt;/code&gt; is what tells the reducer what to do (return a new state or the old one)&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%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fk88s5pljjbm9208y8nml.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%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fk88s5pljjbm9208y8nml.png" alt="Actions are dispatched"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h1&gt;
  
  
  7.
&lt;/h1&gt;

&lt;p&gt;To change data in the store, first write your reducer:&lt;/p&gt;

&lt;p&gt;Reducers are often written with switch/case statements, but don't have to be&lt;/p&gt;

&lt;p&gt;They just have to take in an action and a state, and return a new state&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%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fihgvc66ylih8pguennd8.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%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fihgvc66ylih8pguennd8.png" alt="Reducer with switch case"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h1&gt;
  
  
  8.
&lt;/h1&gt;

&lt;p&gt;It's important that reducers return a NEW state object (and not mutate the old one) so that your components will re-render when something changes&lt;/p&gt;

&lt;p&gt;Don't &lt;em&gt;set&lt;/em&gt; state values in reducers - only ever return a new state object with changed values&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%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fg2zfo5gyj8bkbfbxdofz.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%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fg2zfo5gyj8bkbfbxdofz.png" alt="Do not mutate state"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h1&gt;
  
  
  9.
&lt;/h1&gt;

&lt;p&gt;To dispatch an action, use the &lt;code&gt;useDispatch&lt;/code&gt; hook from react-redux&lt;/p&gt;

&lt;p&gt;call useDispatch with an action object,&lt;/p&gt;

&lt;p&gt;which will run through the reducers,&lt;/p&gt;

&lt;p&gt;and will potentially change the state&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%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fbze9o0yiiqite5fkylyn.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%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fbze9o0yiiqite5fkylyn.png" alt="useDispatch"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h1&gt;
  
  
  10.
&lt;/h1&gt;

&lt;p&gt;All connected components (that call useSelector) will automatically get the new state&lt;/p&gt;

&lt;p&gt;This is treated like props or state changing - useSelector will automatically detect changes and React will re-render the component &lt;/p&gt;

&lt;p&gt;🎉 TADA!&lt;/p&gt;

&lt;h1&gt;
  
  
  That's the basics!
&lt;/h1&gt;

&lt;p&gt;Redux can be used in much more complex ways, but the core is always:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;dispatch an action to the store&lt;/li&gt;
&lt;li&gt;which may or may not change the state via reducers&lt;/li&gt;
&lt;li&gt;access that state with a selector&lt;/li&gt;
&lt;li&gt;and changes will automatically re-render your app&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;💯&lt;/p&gt;

&lt;h1&gt;
  
  
  Code example:
&lt;/h1&gt;

&lt;p&gt;View and play around with the code used in this course on codesandbox:&lt;/p&gt;

&lt;p&gt;&lt;a href="https://codesandbox.io/s/redux-count-hrdtd?fontsize=14" rel="noopener noreferrer"&gt;https://codesandbox.io/s/redux-count-hrdtd?fontsize=14&lt;/a&gt;&lt;/p&gt;

&lt;p&gt; &lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Like this crash course?&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Find more on twitter: &lt;a href="https://twitter.com/chrisachard" rel="noopener noreferrer"&gt;@chrisachard&lt;/a&gt;&lt;br&gt;
Or join my newsletter: &lt;a href="https://chrisachard.com/newsletter/" rel="noopener noreferrer"&gt;https://chrisachard.com/newsletter/&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Thanks for reading!&lt;/p&gt;

</description>
      <category>redux</category>
      <category>react</category>
      <category>javascript</category>
      <category>webdev</category>
    </item>
    <item>
      <title>How I Tripled My Twitter Following in One Weekend by Teaching React</title>
      <dc:creator>Chris Achard</dc:creator>
      <pubDate>Tue, 24 Sep 2019 23:03:39 +0000</pubDate>
      <link>https://forem.com/chrisachard/how-i-tripled-my-twitter-following-in-one-weekend-by-teaching-react-44e5</link>
      <guid>https://forem.com/chrisachard/how-i-tripled-my-twitter-following-in-one-weekend-by-teaching-react-44e5</guid>
      <description>&lt;p&gt;&lt;em&gt;This was originally published here: &lt;a href="https://chrisachard.com/triple-your-twitter-following" rel="noopener noreferrer"&gt;https://chrisachard.com/triple-your-twitter-following&lt;/a&gt;&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;No, it doesn't involve spam or gray-hat techniques or paid ads.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Short Answer:&lt;/strong&gt; Dan Abramov retweeted one of my tweets&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Long Answer:&lt;/strong&gt; I worked really hard creating threads that taught people something, and &lt;em&gt;then&lt;/em&gt; Dan Abramov retweeted one of those threads.  Also, I live tweeted &lt;a href="https://www.reactboston.com/" rel="noopener noreferrer"&gt;React Boston&lt;/a&gt; the whole weekend, though it's hard to say what effect that had.&lt;/p&gt;

&lt;p&gt;It &lt;strong&gt;absolutely&lt;/strong&gt; involved a lot of luck and timing, but as &lt;a href="https://robwalling.com/" rel="noopener noreferrer"&gt;Rob Walling&lt;/a&gt; is a fan of saying: &lt;em&gt;"The harder I work, the luckier I get"&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;Here's what happened:&lt;/p&gt;

&lt;h1&gt;
  
  
  The first few "crash course" threads
&lt;/h1&gt;

&lt;p&gt;On Friday night I had just under 700 followers.  That number was only 400 a couple of weeks before - but I had been producing twitter threads that tried to teach a single concept, like git:&lt;/p&gt;

&lt;p&gt;&lt;a href="https://twitter.com/chrisachard/status/1171124289128554498" rel="noopener noreferrer"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Ffok20ek48e956zch8osg.png" alt="Git crash course"&gt;&lt;/a&gt;&lt;br&gt;
&lt;em&gt;&lt;a href="https://twitter.com/chrisachard/status/1171124289128554498" rel="noopener noreferrer"&gt;https://twitter.com/chrisachard/status/1171124289128554498&lt;/a&gt;&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;And those were doing pretty well.  People seemed to like the format, and I got a lot of messages and comments about how it helped them finally understand the topic. &lt;/p&gt;

&lt;p&gt;Also, I really liked making those threads - it was fun to try to condense such a huge topic down into only a few tweets, so it was all a win-win. 🎊&lt;/p&gt;

&lt;p&gt;&lt;em&gt;(You can find a complete list of the &lt;a href="https://chrisachard.com/crash-courses" rel="noopener noreferrer"&gt;crash course threads here&lt;/a&gt;)&lt;/em&gt;&lt;/p&gt;

&lt;h1&gt;
  
  
  The big one
&lt;/h1&gt;

&lt;p&gt;Then I decided to tackle React head on.  The challenge I put to myself was to teach an intro to React in &lt;em&gt;just 10 tweets&lt;/em&gt;.  It took several attempts and a couple of days to get right, but I finally had something I was proud of!&lt;/p&gt;

&lt;p&gt;It really was an intro to React in just 10 tweets (with supporting images and code), and I put it out on a Friday, just before my flight to &lt;a href="https://www.reactboston.com/" rel="noopener noreferrer"&gt;React Boston&lt;/a&gt; (which was a great conference btw!)&lt;/p&gt;

&lt;p&gt;&lt;a href="https://twitter.com/chrisachard/status/1175022111758442497" rel="noopener noreferrer"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Frrwg76ifsmr46bao3eiy.png" alt="React Crash Course"&gt;&lt;/a&gt;&lt;br&gt;
&lt;em&gt;&lt;a href="https://twitter.com/chrisachard/status/1175022111758442497" rel="noopener noreferrer"&gt;https://twitter.com/chrisachard/status/1175022111758442497&lt;/a&gt;&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;It slowly started to spread, and seemed like it resonated well!  &lt;/p&gt;

&lt;h1&gt;
  
  
  Then it went crazy
&lt;/h1&gt;

&lt;p&gt;Sometime on Saturday, while tweeting about the React conference I was attending, my twitter notifications started going crazy.&lt;/p&gt;

&lt;p&gt;It took me a bit to figure out what happened, but then realized that Dan Abramov (the creator of Redux, and part of the React team at Facebook) had retweeted the React thread! 🎉&lt;/p&gt;

&lt;p&gt;(Thanks Dan!)&lt;/p&gt;

&lt;p&gt;It was the first time anything like that had happened to me, so it was kind of fun watching the Twitter app just give up with notifications, and just get stuck at "20+"&lt;/p&gt;

&lt;p&gt;By the end of the weekend (which I had started with &amp;lt; 700 followers), I had 2,077 (and still growing!)&lt;/p&gt;

&lt;p&gt;&lt;a href="https://twitter.com/chrisachard" rel="noopener noreferrer"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fobvxi6o77aowqn2ae0bt.png" alt="Followers"&gt;&lt;/a&gt;&lt;br&gt;
&lt;em&gt;&lt;a href="https://twitter.com/chrisachard" rel="noopener noreferrer"&gt;https://twitter.com/chrisachard&lt;/a&gt;&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;😲&lt;/p&gt;

&lt;h1&gt;
  
  
  What can we learn...
&lt;/h1&gt;

&lt;p&gt;The goal of the "crash course" twitter threads has always been to teach people new things &lt;em&gt;right on twitter&lt;/em&gt;.  &lt;/p&gt;

&lt;p&gt;This is a style that has been popularized by &lt;a href="https://wesbos.com/" rel="noopener noreferrer"&gt;Wes Bos&lt;/a&gt;, &lt;a href="https://adamwathan.me/" rel="noopener noreferrer"&gt;Adam Wathan&lt;/a&gt; and &lt;a href="https://twitter.com/steveschoger" rel="noopener noreferrer"&gt;Steve Schoger&lt;/a&gt;, and the whole idea is to teach people where they are.&lt;/p&gt;

&lt;p&gt;I knew that if I made really good content, then people would start to take notice (which they did) - but the primary goal of anything like this HAS to be to &lt;strong&gt;teach people stuff&lt;/strong&gt;.  &lt;/p&gt;

&lt;h1&gt;
  
  
  You can do it too
&lt;/h1&gt;

&lt;p&gt;So: make sure that your primary goal is not to gain followers (that will happen organically) - but to &lt;strong&gt;teach as much as you can&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;It took a long time (&lt;strong&gt;years!&lt;/strong&gt;) to find a format that I liked producing that other people clearly like consuming, but I'm happy that I kept at it.&lt;/p&gt;

&lt;p&gt;It's hard work to create content that teaches people complex topics - so keep practicing!  Get feedback, and keep iterating until you find a format that you like as well.&lt;/p&gt;

&lt;h1&gt;
  
  
  The reach of Twitter
&lt;/h1&gt;

&lt;p&gt;So far, that one post has had over 400,000 impressions, and over 15,000 engagements on twitter:&lt;/p&gt;

&lt;p&gt;&lt;a href="https://twitter.com/chrisachard/status/1175022111758442497" rel="noopener noreferrer"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fky6ip71jz7xzk5riflxe.png" alt="400000 engagements"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;It still totally blows my mind how big Twitter is, and how many niches abound. 🤯&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;So what do you want to teach?&lt;/strong&gt;&lt;/p&gt;

&lt;h1&gt;
  
  
  What's next
&lt;/h1&gt;

&lt;p&gt;Well, I already had about 10 more crash courses planned... but now I'm really going to double down. 💯&lt;/p&gt;

&lt;p&gt;The threads that do the best are the ones that take the most time to produce (so I'm ready for that!), but it's definitely worth it - it's clearly a format that people like to learn from, and that helps (based on all the comments I've received).&lt;/p&gt;

&lt;p&gt;If you want to keep up with the courses, then you should obviously &lt;a href="https://twitter.com/chrisachard" rel="noopener noreferrer"&gt;follow me on twitter&lt;/a&gt; 😄&lt;/p&gt;

&lt;p&gt;But also: I encourage you to teach what you know as well!  &lt;/p&gt;

&lt;p&gt;It's difficult but rewarding - and it's the only way I really know to consistently grow your following (if you're into that sort of thing).&lt;/p&gt;

&lt;p&gt;Good luck - and tag me if you do!  I'll check it out 😊&lt;/p&gt;

&lt;p&gt; &lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Like this post?&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;You can find more by following me on twitter 😄: &lt;a href="https://twitter.com/chrisachard" rel="noopener noreferrer"&gt;@chrisachard&lt;/a&gt;&lt;br&gt;
Or by joining my newsletter: &lt;a href="https://chrisachard.com/newsletter/" rel="noopener noreferrer"&gt;https://chrisachard.com/newsletter/&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Thanks for reading!&lt;/p&gt;

</description>
      <category>writing</category>
      <category>react</category>
      <category>motivation</category>
      <category>twitter</category>
    </item>
    <item>
      <title>How to Make the Most of a Tech Conference</title>
      <dc:creator>Chris Achard</dc:creator>
      <pubDate>Tue, 24 Sep 2019 11:42:04 +0000</pubDate>
      <link>https://forem.com/chrisachard/how-to-make-the-most-of-a-tech-conference-3alo</link>
      <guid>https://forem.com/chrisachard/how-to-make-the-most-of-a-tech-conference-3alo</guid>
      <description>&lt;p&gt;&lt;em&gt;This was originally posted on my blog: &lt;a href="https://chrisachard.com/make-the-most-of-a-tech-conference"&gt;https://chrisachard.com/make-the-most-of-a-tech-conference&lt;/a&gt;&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;It can be a big investment for you and your company to send you to a work conference.  Not just the ticket price - but you have to take time away from work and potential disruption to your team's workflow.&lt;/p&gt;

&lt;p&gt;So: how can you be sure that you get the most out of a conference?&lt;/p&gt;

&lt;p&gt;I've just spend the last weekend at the great &lt;a href="https://www.reactboston.com/"&gt;React Boston&lt;/a&gt; conference - so while it's still fresh in my mind, here is what I did, and all my recommendations for you as well.&lt;/p&gt;

&lt;h1&gt;
  
  
  First: decide &lt;strong&gt;why&lt;/strong&gt; you are going
&lt;/h1&gt;

&lt;p&gt;There are many reasons you might want to go to a conference; here are my top three:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Learn new things&lt;/li&gt;
&lt;li&gt;Meet new people&lt;/li&gt;
&lt;li&gt;Take a break from normal work&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Those are all important to me at a conference, so my list of things to do may be different than yours.  &lt;/p&gt;

&lt;p&gt;If your primary motivation for going is simple a mini-vacation: then you can probably ignore the rest of this advice!  But if your primary motivation is to become better at your job, then you'll have to do some actual work at the conference in order to get the most out of it.&lt;/p&gt;

&lt;p&gt;Here's what I recommend:&lt;/p&gt;

&lt;h1&gt;
  
  
  1. Do some research before hand
&lt;/h1&gt;

&lt;p&gt;If you go into a conference totally blind, then you might be overwhelmed by the amount of new technology or terminology that is used.  &lt;/p&gt;

&lt;p&gt;A good conference will progressively expose you to that vocabulary by carefully selecting the order of the talks... but it's still probable that there will be at least a few talks about new topics to yet.&lt;/p&gt;

&lt;p&gt;For that, I recommend two different types of research: &lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Topic research:&lt;/strong&gt; Look at the list of talks and do at least a little bit of research on the topic before hand.  Even just a few minutes of googling about a topic can give you a basic vocabulary about it - so you won't be so lost during the talk.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Speaker research:&lt;/strong&gt; It's also good to look up the speaker list before hand, and get a feel for who they are, and what their background is.  At many tech conferences, you'll be able to interact with the speakers throughout the conference - so it's nice to know at least a little bit about them so you can know their context when you talk to them.&lt;/p&gt;

&lt;p&gt;This research is especially important during a multi-track conference.  How are you supposed to decide what talks to attend, if you don't know anything about the topics or the speakers!  &lt;/p&gt;

&lt;p&gt;So just do a bit of research beforehand (even if it's the night before in your hotel room 😄), and you'll end up with a better, personalized conference.&lt;/p&gt;

&lt;h1&gt;
  
  
  2. Join the conversation
&lt;/h1&gt;

&lt;p&gt;Many conferences today will have at least an active twitter account during the conference - and some have active Slack channels as well.&lt;/p&gt;

&lt;p&gt;Take advantage of that!&lt;/p&gt;

&lt;p&gt;Get Slack loaded onto your phone, introduce yourself in the intros channel - and respond to other people there as well.  I've found that the best conferences I've attended have been the ones with an active Slack channel, with people setting up impromptu coffee meetups, or coordinating dinners.&lt;/p&gt;

&lt;p&gt;Also - if it's your thing - and if the conference has an active twitter presence - consider tweeting at them during the conference!  Twitter is a great way to connect during a tech conference, because much of the audience will be on Twitter as well - so take advantage of that connection.&lt;/p&gt;

&lt;h1&gt;
  
  
  3. Go to bed on time 😅
&lt;/h1&gt;

&lt;p&gt;This one is hard - especially at a multi day conference with nighttime parties - but you'll be no use to yourself if you stay up too late and then are walking-dead the next day.&lt;/p&gt;

&lt;p&gt;So pace yourself!  You are here to have fun (see the points above) - but unless that's your &lt;em&gt;only&lt;/em&gt; goal, you need your sleep too.&lt;/p&gt;

&lt;p&gt;So yes, we're all adults here... but adults need to be reminded of bedtime too 💤&lt;/p&gt;

&lt;h1&gt;
  
  
  4. Leave your laptop in your room
&lt;/h1&gt;

&lt;p&gt;It can be &lt;strong&gt;super&lt;/strong&gt; tempting to bring your laptop and get some quality work time in during the conference... but then &lt;em&gt;what's the point&lt;/em&gt;!?&lt;/p&gt;

&lt;p&gt;If you bring your laptop and open it during the talks "just to check some email" - you'll get distracted.  I &lt;em&gt;guarantee&lt;/em&gt; it. &lt;/p&gt;

&lt;p&gt;So do yourself a favor and leave your laptop in your room.&lt;/p&gt;

&lt;p&gt;I do recommend good old fashioned pen and paper for notes though. 📓&lt;/p&gt;

&lt;h1&gt;
  
  
  5. Bring a backup phone battery
&lt;/h1&gt;

&lt;p&gt;So you've left your laptop in your room - but let's be real... you need SOME connection to the outside world 😆&lt;/p&gt;

&lt;p&gt;Since you'll be on your phone more than normal, in a building with probably not-so-great reception, and far away from your room with a power cord... you'll want an extra battery.&lt;/p&gt;

&lt;p&gt;I have one (that I got for free from another conference) that is tiny and just slips into my pocket, and holds about one extra charge for my phone.  &lt;/p&gt;

&lt;p&gt;Perfect!&lt;/p&gt;

&lt;h1&gt;
  
  
  6. Actually meet new people
&lt;/h1&gt;

&lt;p&gt;If one of your goals is to meet you people (and if not - then why not just watch the conference on youtube later?) - then you have to &lt;em&gt;actually walk around and meet new people!&lt;/em&gt;.&lt;/p&gt;

&lt;p&gt;Yes, it will be uncomfortable, and yes, it will be a little weird - but remember; the other people are at this conference to meet new people as well!&lt;/p&gt;

&lt;p&gt;So don't just stand around waiting for people to come talk to you - you have to actually go talk to them.&lt;/p&gt;

&lt;p&gt;My favorite pro tip for this is to walk up to a circle of people speaking and just say:&lt;/p&gt;

&lt;p&gt;"Can I join your circle here?"&lt;/p&gt;

&lt;p&gt;... I don't think anyone has &lt;em&gt;ever&lt;/em&gt; said no to that - and I always have a good conversation!&lt;/p&gt;

&lt;p&gt;It does take practice, but it's worth the practice.&lt;/p&gt;

&lt;h1&gt;
  
  
  7. Go to the events
&lt;/h1&gt;

&lt;p&gt;A lot of the conference is not going to just happen during the talks.  If you really want to get to know the other attendees and speakers:&lt;/p&gt;

&lt;p&gt;That's what the events are for!&lt;/p&gt;

&lt;p&gt;Most conferences have at least one party or social night included - so make sure you go.  &lt;/p&gt;

&lt;p&gt;While you're there, practice number 6 (actually talking to people), and go with no agenda - just have fun!  You'll learn new things and meet new people, which are 2 of the primary reasons you're going, right?&lt;/p&gt;

&lt;h1&gt;
  
  
  8. Take a break when you need to
&lt;/h1&gt;

&lt;p&gt;Obviously you need to watch out for your own energy and health.  &lt;/p&gt;

&lt;p&gt;If you haven't slept well in the hotel, and you just need a break - then there's no shame in just going back to your hotel room to take a bit of a nap.&lt;/p&gt;

&lt;p&gt;You're no use to yourself (or others!) if you can't function; so take the break that you need to, and then come back ready to learn and meet people 🎉&lt;/p&gt;

&lt;h1&gt;
  
  
  9. Spend some time afterwards to decompress
&lt;/h1&gt;

&lt;p&gt;Finally - conferences have a way of packing your brain with new knowledge and ideas.  If you just go back to work on Monday without processing all of that new information though - you won't be able to turn those new ideas into actions.&lt;/p&gt;

&lt;p&gt;I like to spend at least an hour (longer if I can) just writing down the ideas I heard during the conference, and how I'm going to apply them in my job.&lt;/p&gt;

&lt;p&gt;If you're flying back the next day, then that is a &lt;em&gt;great&lt;/em&gt; time to do a &lt;strong&gt;decompress journal&lt;/strong&gt;.  When you turn off your laptop and phone during takeoff, just take out a notebook instead and start writing.&lt;/p&gt;

&lt;p&gt;I'm always surprised at how much detailed, actionable data comes out of my head during these writing sessions; and I can guarantee that I would have forgotten most of it if I didn't take the time to write it down.&lt;/p&gt;

&lt;h1&gt;
  
  
  Have fun!
&lt;/h1&gt;

&lt;p&gt;So that's it - know why you're going, and then when you show up - actually show up!&lt;/p&gt;

&lt;p&gt;Be prepared to learn; meet new people; but also to have fun.&lt;/p&gt;

&lt;p&gt;Conferences are a way to get yourself out of your normal element, and to pack your brain with new information that you can apply at work - so take advantage of that change of scenery.&lt;/p&gt;

&lt;p&gt; &lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Like this post?&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;You can follow me on twitter: &lt;a href="https://twitter.com/chrisachard"&gt;@chrisachard&lt;/a&gt;&lt;br&gt;
Or join the newsletter for more: &lt;a href="https://chrisachard.com/newsletter"&gt;https://chrisachard.com/newsletter&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Thanks for reading!&lt;/p&gt;

</description>
      <category>career</category>
      <category>motivation</category>
      <category>beginners</category>
    </item>
  </channel>
</rss>
