Dismissing Keyboards in React Native Views

When a using a View in React Native, you don't have any control over the keyboard. So, if the view has an input field and the user taps away from the input field, the keyboard will remain visible. The user has no way to get rid of the keyboard. { failureMessage…

Partially Stashing Files in Git

Imagine that to run an app locally, you need to change a configuration file. No matter what branch you are currently on, this configuration file will need to remain the same. Let's call it config.js. Now, you're working on a topic branch feature-a and have 2 edited files (a…

Adding to Redux-form FieldArray

Imagine you're creating a form that needs multiple discount codes for a checkout process. In React/React Native, you might use a FieldArray from the redux-form library. It could look something like this: Submit export const discounts = ({ fields }) => ( {fields.map((code, index) => ( fields.remove(index)}> × ))} fields.push()}> Add {!fields…

Debugging Implicit Returns in ES6

For the last 3.5 years, I've worked on a AngularJS(1.x) project; so, I haven't had lots of opportunity to use many of the new features in ES6. Now that I'm doing React Native work, I've been loving all these new features. However, one thing I really haven't…

Configuring Jest in React Native 0.57.0

I'm trying to get a baseline React Native app setup. Unfortunately, I kept running into problems with configuring Jest. When I run yarn test, I'd get this failure: $ yarn test yarn run v1.6.0 warning ../../../package.json: No license field $ jest FAIL ./App.test.js ‚óŹ Test suite failed to…

E2E Testing Angular Apps with Cypress.io

UPDATE : Gleb Bahmutov, from the Cypress team, was kind enough to put together a blog post explaining how to solve my issue. I have to admit that I've rarely done unit testing or end to end testing with any of the Ionic framework apps I've developed. I've tried several times…