<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Peter Springer on Medium]]></title>
        <description><![CDATA[Stories by Peter Springer on Medium]]></description>
        <link>https://medium.com/@peterspringer829?source=rss-122e7983492e------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*qXKFyAYmRRDMSgYXxRcAsg.jpeg</url>
            <title>Stories by Peter Springer on Medium</title>
            <link>https://medium.com/@peterspringer829?source=rss-122e7983492e------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Sun, 22 Nov 2026 02:55:38 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@peterspringer829/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[Getting Started with Kafka]]></title>
            <link>https://medium.com/@peterspringer829/getting-started-with-kafka-5b44759d11d8?source=rss-122e7983492e------2</link>
            <guid isPermaLink="false">https://medium.com/p/5b44759d11d8</guid>
            <category><![CDATA[java]]></category>
            <category><![CDATA[javascript]]></category>
            <category><![CDATA[websocket]]></category>
            <category><![CDATA[web-development]]></category>
            <category><![CDATA[kafka]]></category>
            <dc:creator><![CDATA[Peter Springer]]></dc:creator>
            <pubDate>Wed, 30 May 2018 02:45:32 GMT</pubDate>
            <atom:updated>2018-05-30T02:45:32.044Z</atom:updated>
            <content:encoded><![CDATA[<p>The steps listed below are intended to provide a quick intro to get you started using Kafka.</p><p><strong>Step 1: Download some code and place it in a directory</strong></p><p>You want to download 1.1.0 from <a href="https://www.apache.org/dyn/closer.cgi?path=/kafka/1.1.0/kafka_2.11-1.1.0.tgz"><strong>here</strong></a></p><p><strong>Step 2: Rename the unzipped directory you just downloaded to kafka(optional)</strong></p><p>You can choose to ignore this step but will need to update your paths where necessary since they will not match mine.</p><p><strong>Step 3: Update the server.properties file</strong></p><p>add the following code to kafka/config/server.properties</p><pre>port = 9092<br>advertised.listener = localhost</pre><p><strong>Step 4: Start the ZooKeeper server</strong></p><p>kafka/bin/zookeeper-server-start.sh kafka/config/zookeeper.properties</p><p><strong>Step 5: Start the Kafka server in a new tab or pane</strong></p><pre>kafka/bin/kafka-server-start.sh kafka/config/server.properties</pre><p><strong>Step 6: Create your topic</strong></p><pre>kafka/bin/kafka-topics.sh --create --zookeeper localhost:2181 --replication-factor 1 --partitions 1 --topic my-topic</pre><p><strong>Step 7: List your topic</strong></p><pre>kafka/bin/kafka-topics.sh --list --zookeeper localhost:2181</pre><p>You should see your topic name print to the terminal</p><p><strong>Step 8: Start your producer in a new tab or pane</strong></p><pre>kafka/bin/kafka-console-producer.sh --broker-list localhost:9092 --topic my-topic</pre><p><strong>Step 9: Start your consumer in a new tab or pane</strong></p><pre>kafka/bin/kafka-console-consumer.sh --bootstrap-server localhost:9092 --topic my-topic --from-beginning</pre><p><strong>Step 10: Navigate back to your producer tab and send your first message</strong></p><p>type a new message and hit enter</p><pre>$ kafka/bin/kafka-console-producer.sh --broker-list localhost:9092 --topic my-topic<br>&gt;wow<br>&gt;</pre><p><strong>Finally: Navigate back to your consumer tab and view the message you just sent!</strong></p><pre>$ kafka/bin/kafka-console-consumer.sh --bootstrap-server localhost:9092 --topic my-topic --from-beginning<br>wow</pre><p>If you encounter issues stopping your kafka server run the following command while your zookeeper server is still running.</p><pre>kafka/bin/kafka-server-stop.sh config/server.properties</pre><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=5b44759d11d8" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Using Tailwind CSS With Create React App]]></title>
            <link>https://medium.com/@peterspringer829/using-tailwind-css-with-create-react-app-3ada48c7ad7b?source=rss-122e7983492e------2</link>
            <guid isPermaLink="false">https://medium.com/p/3ada48c7ad7b</guid>
            <category><![CDATA[css]]></category>
            <category><![CDATA[javascript]]></category>
            <category><![CDATA[react]]></category>
            <dc:creator><![CDATA[Peter Springer]]></dc:creator>
            <pubDate>Wed, 28 Feb 2018 17:07:11 GMT</pubDate>
            <atom:updated>2018-02-28T17:07:11.896Z</atom:updated>
            <content:encoded><![CDATA[<p>Using Tailwind CSS With Create React App</p><p>Tailwind is a CSS framework based around low level utility classes. If you would like a deeper dive into the WHAT of Tailwind you can view the documentation <a href="https://tailwindcss.com/">HERE</a>. Configuring a new dependency within a <a href="https://github.com/facebook/create-react-app">Create React App</a> project can be a challenge at times. Below you will find step by step instructions for setting up Tailwind within a project created using <a href="https://github.com/facebook/create-react-app">Create React App</a>.</p><ol><li>Install Tailwind</li></ol><pre>npm i tailwindcss --save-dev</pre><p>2. Create a Tailwind config file</p><p>Tailwind has created a CLI utility that will create a tailwind.js file in your project’s root.</p><pre>./node_modules/.bin/tailwind init [filename]</pre><p>3. Inject Tailwind’s preflight and utilities styles into your main CSS file. This is the CSS file that is imported into your index.js</p><p>Add the following directives into your index.css</p><pre><a href="http://twitter.com/tailwind">@tailwind</a> preflight;<br><a href="http://twitter.com/tailwind">@tailwind</a> utilities;</pre><p>4. Update webpack.config files</p><p>Create react app does not give you access to the webpack.config files by default. You will need to eject to access these files.</p><pre>npm run eject</pre><p>5. Update necessary webpack files</p><pre>const tailwindcss = require(&#39;tailwindcss&#39;);<br>module.exports = {<br>  plugins: [<br>    // ...<br>    tailwindcss(&#39;./tailwind.js&#39;),<br>    require(&#39;autoprefixer&#39;),<br>    // ...<br>  ]<br>}</pre><p>6. Add a Tailwind class and start your application</p><p>add a class to the element of your choice</p><pre>&lt;h1 className=&quot;text-red hover:text-red-dark&quot;&gt;Welcome to React&lt;/h1&gt;</pre><p>start the app</p><pre>npm start</pre><p>👍</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=3ada48c7ad7b" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Getting Started With React Native]]></title>
            <link>https://medium.com/front-end-weekly/getting-started-with-react-native-1eedf16f2e18?source=rss-122e7983492e------2</link>
            <guid isPermaLink="false">https://medium.com/p/1eedf16f2e18</guid>
            <category><![CDATA[reactjs]]></category>
            <category><![CDATA[react-native]]></category>
            <category><![CDATA[javascript]]></category>
            <dc:creator><![CDATA[Peter Springer]]></dc:creator>
            <pubDate>Tue, 27 Dec 2016 21:51:18 GMT</pubDate>
            <atom:updated>2016-12-27T21:51:18.344Z</atom:updated>
            <content:encoded><![CDATA[<p>When I hear React I immediately think of using React for web development. However React can be used across many platforms. If you have ever looked at the React docs or listened to a talk on React you have most likely been exposed to the tag line “Learn Once Write Anywhere”. I recently dipped my toes into React Native and found myself pleasantly surprised with just how true that statement is.</p><p>However despite it feeling very familiar you will still be exposed to a few “gotchas” worth mentioning. The first one being applying styling. The styling is typically scoped to the component it lives in and applied using inline styles. Here is a good example of what that might look like from the React Native docs.</p><pre>import React, { Component } from &#39;react&#39;;<br>import { AppRegistry, StyleSheet, Text, View } from &#39;react-native&#39;;</pre><pre>class LotsOfStyles extends Component {<br>  render() {<br>    return (<br>      &lt;View&gt;<br>        &lt;Text style={styles.red}&gt;just red&lt;/Text&gt;<br>        &lt;Text style={styles.bigblue}&gt;just bigblue&lt;/Text&gt;<br>        &lt;Text style={[styles.bigblue, styles.red]}&gt;<br>          bigblue, then red<br>        &lt;/Text&gt;<br>        &lt;Text style={[styles.red, styles.bigblue]}&gt;<br>          red, then bigblue<br>        &lt;/Text&gt;<br>      &lt;/View&gt;<br>    );<br>  }<br>}</pre><pre>const styles = StyleSheet.create({<br>  bigblue: {<br>    color: &#39;blue&#39;,<br>    fontWeight: &#39;bold&#39;,<br>    fontSize: 30,<br>  },<br>  red: {<br>    color: &#39;red&#39;,<br>  },<br>});</pre><pre>AppRegistry.registerComponent(&#39;LotsOfStyles&#39;, () =&gt; LotsOfStyles);</pre><p>The next “gotcha” you will probably encounter is building your components out of a number of prebuilt components that you may be unfamiliar with compared to hand rolling all of your own JSX. A few common examples are View, ScrollView and TouchableHighlight. Lets take a look at what the code may look like for these.</p><pre>View:</pre><pre>class ViewColoredBoxesWithText extends Component {<br>   render() {<br>     return (<br>       &lt;View style={{flexDirection: &#39;row&#39;, height: 100}}&gt;<br>         &lt;View style={{backgroundColor: &#39;blue&#39;, flex: 0.3}} /&gt;<br>         &lt;View style={{backgroundColor: &#39;red&#39;, flex: 0.5}} /&gt;<br>         &lt;Text&gt;Hello World!&lt;/Text&gt;<br>       &lt;/View&gt;<br>     );<br>   }<br> }</pre><pre>ScrollView:</pre><pre>class IScrolledDownAndWhatHappenedNextShockedMe extends Component {<br>  render() {<br>      return(<br>        &lt;ScrollView&gt;<br>          &lt;Text style={{fontSize:96}}&gt;Scroll me plz&lt;/Text&gt;<br>          &lt;Image source={require(&#39;./img/favicon.png&#39;)} /&gt;<br>          &lt;Image source={require(&#39;./img/favicon.png&#39;)} /&gt;<br>          &lt;Image source={require(&#39;./img/favicon.png&#39;)} /&gt;<br>          &lt;Image source={require(&#39;./img/favicon.png&#39;)} /&gt;<br>          &lt;Image source={require(&#39;./img/favicon.png&#39;)} /&gt;<br>          &lt;Text style={{fontSize:96}}&gt;If you like&lt;/Text&gt;<br>          &lt;Image source={require(&#39;./img/favicon.png&#39;)} /&gt;<br>          &lt;Image source={require(&#39;./img/favicon.png&#39;)} /&gt;<br>          &lt;Image source={require(&#39;./img/favicon.png&#39;)} /&gt;<br>          &lt;Image source={require(&#39;./img/favicon.png&#39;)} /&gt;<br>          &lt;Image source={require(&#39;./img/favicon.png&#39;)} /&gt;<br>        &lt;/ScrollView&gt;<br>    );<br>  }<br>}</pre><pre>TouchableHighlight: </pre><pre>var TappyButtonApp = React.createClass({  <br>  getInitialState() {<br>    return {<br>      score: 0<br>    }<br>  },<br>  render() {<br>    return (<br>      &lt;View style={styles.container}&gt;<br>        &lt;Text style={styles.label}&gt;<br>         {&#39;Score: &#39; + this.state.score}<br>        &lt;/Text&gt;<br>        &lt;TouchableHighlight<br>          activeOpacity={0.6}<br>          underlayColor={&#39;white&#39;}<br>          onPress={() =&gt; this.setState({score:++this.state.score})}&gt;<br>          &lt;Text style={styles.button}&gt;Tap&lt;/Text&gt;<br>        &lt;/TouchableHighlight&gt;<br>      &lt;/View&gt;<br>   );<br>  }<br>});</pre><p>Finally since iOS and Android have their own unique design guidelines your code will not be 100% reusable across platforms. There appears to be a few React Native libraries out there working towards a truly singular codebase to handle both platforms but I have not tried any yet. I have also seen statements that will render different components or styles based on a conditional that checks the OS. Something similar to…</p><pre>if (Platform.OS === &#39;android&#39;) Do Something </pre><p>For now I would probably opt for two entirely separate code bases mainly to avoid hating myself while debugging 6 months down the road but that is just my opinion. Hopefully this is helpful for anyone thinking about getting started with React Native.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=1eedf16f2e18" width="1" height="1" alt=""><hr><p><a href="https://medium.com/front-end-weekly/getting-started-with-react-native-1eedf16f2e18">Getting Started With React Native</a> was originally published in <a href="https://medium.com/front-end-weekly">Frontend Weekly</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Using Vue.js For the First Time]]></title>
            <link>https://medium.com/@peterspringer829/using-vue-js-for-the-first-time-45ff7fa94833?source=rss-122e7983492e------2</link>
            <guid isPermaLink="false">https://medium.com/p/45ff7fa94833</guid>
            <category><![CDATA[reactjs]]></category>
            <category><![CDATA[react]]></category>
            <category><![CDATA[vuejs]]></category>
            <category><![CDATA[javascript]]></category>
            <dc:creator><![CDATA[Peter Springer]]></dc:creator>
            <pubDate>Sun, 11 Dec 2016 18:35:41 GMT</pubDate>
            <atom:updated>2016-12-11T18:35:41.514Z</atom:updated>
            <content:encoded><![CDATA[<p>The number of front-end frameworks can be overwhelming. This post aims to relieve some anxiety for anyone who knows their way around a React app and is interested in picking up Vue for their first time. Something that I find invaluable when learning something new is a comparison to something I already know. That being said this post will use code samples in an effort to explain similarities between Vue and React. Some of these comparison may appear obvious or overly simplistic…that’s the point! If you already know React you know more about Vue than you think.</p><p>Just like React, Vue is used for single page apps. So we’ll need to inject our components into either a index.html or index.ejs file.</p><pre>example of index.html</pre><pre>&lt;!DOCTYPE html&gt;<br>&lt;html&gt;<br>  &lt;head&gt;<br>    &lt;meta charset=&quot;utf-8&quot;&gt;<br>    &lt;title&gt;vue-example-project&lt;/title&gt;<br>  &lt;/head&gt;<br>  &lt;body&gt;<br>    &lt;div id=&quot;app&quot;&gt;&lt;/div&gt;<br>  &lt;/body&gt;<br>&lt;/html&gt;</pre><p>Injecting App component into index.html:</p><pre>React implementation:</pre><pre>const React = require(&#39;react&#39;);<br>const ReactDOM = require(&#39;react-dom&#39;);<br>import App from &#39;./components/App&#39;;</pre><pre>ReactDOM.render(&lt;App /&gt;, document.getElementById(&#39;application&#39;))</pre><pre>Vue implementation:</pre><pre>import Vue from &#39;vue&#39;<br>import App from &#39;./App&#39;</pre><pre>new Vue({<br>  el: &#39;#app&#39;,<br>  template: &#39;&lt;App/&gt;&#39;,<br>  components: { App }<br>})</pre><p>Next lets compare what a component might look like.</p><pre>React implementation:</pre><pre>import Header from &#39;./Header&#39;;</pre><pre>class App extends React.Component {</pre><pre>render() {<br>    return (<br>      &lt;section&gt;<br>        &lt;Header/&gt;<br>      &lt;/section&gt;<br>    )<br>  }<br>}</pre><pre>export default App;</pre><pre>Vue implementation:</pre><pre>&lt;template&gt;<br>  &lt;div id=&quot;app&quot;&gt;<br>    &lt;hello&gt;&lt;/hello&gt;<br>  &lt;/div&gt;<br>&lt;/template&gt;</pre><pre>&lt;script&gt;<br>import Hello from &#39;./components/Hello&#39;</pre><pre>export default {<br>  name: &#39;app&#39;,<br>  components: {<br>    Hello<br>  }<br>}<br>&lt;/script&gt;</pre><pre>&lt;style&gt;<br>#app {<br> color: green;<br>}<br>&lt;/style&gt;</pre><p>Right away we can notice a few syntax differences. But the concepts are exactly the same. Template is the Vue equivalent to render(). Functionality<br>will be written in-between the script tags and lastly you will typically see each component with it’s own style tags that are scoped to the component they live inside of.</p><p>Passing a component:</p><pre>React implementation:</pre><pre>import Header from &#39;./Header&#39;;</pre><pre>class App extends React.Component {</pre><pre>render() {<br>    return (<br>      &lt;section&gt;<br>        &lt;Header/&gt;<br>      &lt;/section&gt;<br>    )<br>  }<br>}</pre><pre>export default App;</pre><pre>Vue implementation:</pre><pre>&lt;template&gt;<br>  &lt;div id=&quot;app&quot;&gt;<br>    &lt;hello&gt;&lt;/hello&gt;<br>  &lt;/div&gt;<br>&lt;/template&gt;</pre><pre>&lt;script&gt;<br>import Hello from &#39;./components/Hello&#39;</pre><pre>export default {<br>  name: &#39;app&#39;,<br>  components: {<br>    Hello<br>  }<br>}<br>&lt;/script&gt;</pre><pre>The import occurs between the script tags then the component can be placed into the template.</pre><p>Setting state:</p><pre>React implementation:</pre><pre>constructor(props) {<br>    super(props);<br>    this.state = {<br>      initialState: &#39;Hello&#39;,<br>      secondaryState: &#39;World&#39;,<br>    };<br>  }</pre><pre>Vue implementation:</pre><pre>data () {<br>    return {<br>      initialState: &#39;Hello&#39;,<br>      secondaryState: &#39;World&#39;<br>    }<br>  }</pre><p>Creating props:</p><pre>React implementation:</pre><pre>render() {<br>    return (<br>      &lt;div className=&quot;app-container&quot;&gt;<br>        &lt;ComponentOne<br>          propOne={this.state.initialState}<br>          propTwo={this.state.secondaryState}<br>        /&gt;<br>      &lt;/div&gt;<br>    );<br>  }</pre><pre>Vue implementation:</pre><pre>&lt;template&gt;<br>  &lt;div class=&quot;app&quot;&gt;<br>    &lt;component-one<br>      :propOne=&#39;initialState&#39;<br>      :propTwo=&#39;secondaryState&#39;<br>    &lt;/component-one&gt;<br>  &lt;/div&gt;<br>&lt;/template&gt;</pre><p>Hopefully you found these comparisons useful. Here is a link to the <a href="https://vuejs.org/">Vue docs </a>.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=45ff7fa94833" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>