Customer Service & Support Contact Information
Contact Name: Christopher Pedersen
Contact Phone Number: +1 (469) 261-0727
Contact Email: chrispedatx [at] gmail.com
Contact Name: Christopher Pedersen
Contact Phone Number: +1 (469) 261-0727
Contact Email: chrispedatx [at] gmail.com
Your privacy is important to me. It is my (Christopher Pedersen) policy to respect your privacy regarding any information I may collect from you on my app, “Happening Now…”.
I only ask for personal information when we truly need it to provide a service to you. I collect it by fair and lawful means, with your knowledge and consent. I also let you know why I am collecting it and how it will be used.
I only retain collected information for as long as necessary to provide you with your requested service. What data I store, I will protect within commercially acceptable means to prevent loss and theft, as well as unauthorized access, disclosure, copying, use or modification.
I don’t share any personally identifying information publicly or with third-parties, except when required to by law.
My app may link to external sites that I do not operate. Please be aware that I have no control over the content and practices of these sites, and cannot accept responsibility or liability for their respective privacy policies.
You are free to refuse our request for your personal information, with the understanding that I may be unable to provide you with some of your desired services.
Your continued use of my website will be regarded as acceptance of our practices around privacy and personal information. If you have any questions about how I handle user data and personal information, feel free to contact me (chris@topherpedersen.com).
This policy is effective as of 01 February 2020.
This blog post is brought to you by the developer of BitBudget. BitBudget is an automated budgeting app for Android and iOS which syncs with your bank account and helps you avoid overspending. If you’d like to quit living paycheck-to-paycheck and get a better handle on your finances, download it today! https://bitbudget.io
Having trouble getting your images to show up in the launch screen of your iPhone app? The answer to this problem is pretty ridiculous: reboot your device! I was riding the struggle bus for awhile trying to uncover the answer to this doozy before stumbling upon Flexicoder’s answer on Stack Overflow.
The first thing I tried doing was to run the app on the simulator instead of on my physical iPhone, and sure enough my launch screen image showed up right away. Then after rebooting my iPhone, I was able to get the launch screen image to start displaying on my physical device as well. So cheers to Flexicoder and his solution which have been upvoted 270 times:
This blog post is brought to you by the developer of BitBudget. BitBudget is an automated budgeting app for Android and iOS which syncs with your bank account and helps you avoid overspending. If you’d like to quit living paycheck-to-paycheck and get a better handle on your finances, download it today! https://bitbudget.io
Confession: I hate Git. Heresy, I know. But true nonetheless. And I suppose that’s what brings you here. You made a mistake. You pushed several commits to the MASTER branch of your GitHub repository, but have now have had a change of heart. You’ve decided that you’d like to go back to the good ol days, a few commits ago actually. That’s what you want, but Git doesn’t care.
Awful isn’t it!?!? All you want to do is something fairly straight forward, reset your project back to a previous point in time, and Git does not want to allow you to do this. Checkout a previous commit? No problem! Push this commit to MASTER? Absolutely not!
Well luckily, I found an excellent tutorial on YouTube tonight on how to do this. It isn’t super simple. It probably isn’t the way the professionals do it. It probably doesn’t follow “best practices.” However, it works:
This blog post is brought to you by the developer of BitBudget. BitBudget is an automated budgeting app for Android and iOS which syncs with your bank account and helps you avoid overspending. If you’d like to quit living paycheck-to-paycheck and get a better handle on your finances, download it today! https://bitbudget.io
Welcome back internet friend,
At the moment I’m currently doing a little hacking in Golang, and just wanted to post this quick little example of how to work with an api and parse json data in Go. Unlike some of the other languages I’ve worked with, in Golang you will need to create a struct to represent the JSON data you are receiving from the API endpoint you are hitting. That’s the trickiest part in my opinion. Also, the JSON data you will be working with is going to be an array of bytes, not a string. Last, you’ll use json.Unmarshal to parse your JSON and extract the information you are looking for.
Unfortunately, I don’t have time to write up a detailed post about how all of this works. However, I think the code snippet below is pretty cool and should provide a good reference if you happen to be playing around with APIs and JSON using Go. Note, the code below is using RapidAPI’s Hacker News endpoint to provide the JSON data. So if you’d like to try running this code yourself, make sure to visit rapidapi.com, register for an account, and replace the API key below with your own. Enjoy!
UPDATE (1/27/2020): Remember to use a JSON to Golang Struct Conversion Tool such as JSON-to-Go to easily map Golang Structs to the JSON objects you want to decode. The code snippet below provides a good example of a struct created with JSON-to-Go:
This blog post is brought to you by the developer of BitBudget. BitBudget is an automated budgeting app for Android and iOS which syncs with your bank account and helps you avoid overspending. If you’d like to quit living paycheck-to-paycheck and get a better handle on your finances, download it today! https://bitbudget.io
Welcome back dear internet friend!
Having trouble getting started with WebSockets in React Native? I’ve got the answer you’re looking for! After many hours of messing around with WebSockets in React Native for the first time today I’ve made some discoveries that hopefully will be of use to someone else out there on the internet.
First, avoid Socket.IO. When attempting to tackle this problem I naturally started with Socket.IO as I’ve used it before in the past, it’s sort of the #1 name in WebSocket programming, so it would make sense as a good starting point. However, I had a little trouble getting it to work. Now in all fairness to Socket.IO, their WebSocket library may not have been the problem in my setup. But along my winding path today I discovered that Socket.IO doesn’t work “out of the box” in React Native, and while it does work, it actually falls back upon HTTP Long Polling if you simply install it in your project with modification. Furthermore, the official React Native documentation specifically mentions the built-in WebSocket API that comes with JavaScript, so I would recommend using that.
The next stumbling block you might run into is setting up your own WebSocket server. For me, this ended up being a lot trickier than simply setting up a WebSocket server for a web app. I have setup WebSocket servers for both NodeJS and Flask web apps fairly easily, but doing the same with React Native gave me a lot of problems. So what I found extremely helpful was to use a test endpoint from a 3rd party that simply echos back any WebSocket messages sent from my app.
After a days work fumbling around, riding the struggle bus, I present a super simple quick start template for getting up and running with WebSockets in React Native. The endpoint URL in the code points to the 3rd party WebSocket test endpoint described above, so the solution below should work as is with no modification necessary. Just create a new React Native app, delete the contents of your App.js file, and copy & paste the code below, and you should be well on your way! (and this way, you will know your React Native app is working properly and playing nice with WebSockets before you start messing around with your server side code. Also, remember to avoid Socket.IO if you want to use the built-in WebSocket API like in my example:
EDIT: According to notable developer Miguel Grinberg, Socket.IO will not fall back upon HTTP Long Polling in React Native if you specify that you want to use [websockets] as your transport method. But never let the truth get in the way of a good story, so I’m leaving this post unedited 😉
This blog post is brought to you by the developer of BitBudget. BitBudget is an automated budgeting app for Android and iOS which syncs with your bank account and helps you avoid overspending. If you’d like to quit living paycheck-to-paycheck and get a better handle on your finances, download it today! https://bitbudget.io
Cheatsheet reference for handling command line user input in Golang:
This blog post is brought to you by the developer of BitBudget. BitBudget is an automated budgeting app for Android and iOS which syncs with your bank account and helps you avoid overspending. If you’d like to quit living paycheck-to-paycheck and get a better handle on your finances, download it today! https://bitbudget.io
Over the past two days I’ve been pretty stumped working on this new database for my latest app, Moolabeast. I’ve been experimenting with different table designs etc., and discovered what I really need is a FULL JOIN. Great! But just one problem… MySQL doesn’t support FULL JOINS. Yikes!
On StackOverflow I found a bunch of different posts from developers describing how to “fake” a FULL JOIN using various SQL statements that were a little beyond my comprehension. However, I finally found an excellent blog post from TablePlus explaining how this works.
Therefore, if you find yourself struggling to do a FULL JOIN in MySQL, I suggest checking out TablePlus’s explanation. I don’t think I could do it justice! It took me a while to find a really good post on the subject, thus that’s why I wanted to write this post to point more people in the right direction.
Essentially you need to do a LEFT JOIN, and a RIGHT JOIN, and then a UNION which will merge the results of the two joins. Now it isn’t perfect, but it’s probably close enough:
Nifty ven diagrams from TablePlus demonstrating the UNION of the LEFT JOIN and RIGHT JOIN results to create a FULL JOIN:
This blog post is brought to you by the developer of BitBudget. BitBudget is an automated budgeting app for Android and iOS which syncs with your bank account and helps you avoid overspending. If you’d like to quit living paycheck-to-paycheck and get a better handle on your finances, download it today! https://bitbudget.io
Having trouble dismissing the keyboard in your React Native app on iOS? Would you like the keyboard to simply go away after a user taps somewhere else on the screen after entering some text into a TextInput? Here’s what you’re looking for: <TouchableWithoutFeedback> and Keyboard.dismiss() are the React Native equivalents of Tap Gesture Recognizer and resignFirstResponder. Simply wrap your view in a <TouchableWithoutFeedback> component and call the Keyboard.dismiss() method onPress and the keyboard will automatically dismiss itself when a user taps an area of the screen outside of the currently selected <TextInput>:
This blog post is brought to you by the developer of BitBudget. BitBudget is an automated budgeting app for Android and iOS which syncs with your bank account and helps you avoid overspending. If you’d like to quit living paycheck-to-paycheck and get a better handle on your finances, download it today! https://bitbudget.io
Welcome back dear internet friend!
Quick little rant and opinion piece here tonight on the blog. I’ve been programming a lot lately in ReactJS and React-Native, following along with all of the various quickstart guides and tutorials related to the React tech stack, and have found myself thrust into this brave new world of JavaScript where variables do not exist. In this new world var is out, and const is in!
At least that’s how it appears looking at all of this “modern” JavaScript code I’ve been working with. I can’t remember the last time I saw the keyword var. But tonight I sort of had an epiphany: These constants don’t seem very constant to me. We’re using them just like variables!
To test this out, I fired up repl to see, can you just write over a constant whenever you feel like it? Or if you declare a new constant with the same name, is all forgiven? Well here’s what I found out. The JavaScript interpreter will get mad at you and crash if you try to write over a constant, or declare a new constant with the same name. But, if you declare a new constant inside a function you can write over it as many times as you like!
So… essentially this is what I’ve been seeing in all the modern JavaScript code I’ve been looking at. People are using constants just like variables, except the constants are always inside of a render() function or something similar so you can keep writing over it over and over and over again.
I’m sure most professional React developers know this. However, this seems pretty stupid to me. Why use a constant if you actually want a variable? I’m sure the answer has something to do with immutability! and functional programming! But I’m not buying it. const is not constant, and the emperor has no clothes.