[Home][Portfolio]Blog

Josh as a Developer

<<< Go backDefault image for blog post when there is not an image to show

React Native Animations Example

June 05, 2022 read in 1 minute
1/**
2 * Sample React Native App
3 * https://github.com/facebook/react-native
4 *
5 * @format
6 * @flow strict-local
7 */
8
9import React, {Node, useEffect, useState} from 'react';
10import {Animated, StyleSheet} from 'react-native';
11
12const styles = StyleSheet.create({
13  container: {
14    flex: 1,
15    alignItems: 'center',
16    justifyContent: 'center',
17  },
18  box: {
19    height: 100,
20    width: 100,
21  },
22});
23
24const App: () => Node = () => {
25  const [animation, setAnimation] = useState(new Animated.Value(0));
26
27  useEffect(() => {
28    Animated.timing(animation, {
29      toValue: 1,
30      duration: 5000,
31      useNativeDriver: false,
32    }).start();
33  }, []);
34
35  const bgStyle = {
36    backgroundColor: animation.interpolate({
37      inputRange: [0, 1],
38      outputRange: ['rgba(255,99,71, 1)', 'rgba(255,99,71, 0)'],
39    }),
40  };
41  const boxStyle = {
42    backgroundColor: animation.interpolate({
43      inputRange: [0, 1],
44      outputRange: ['rgb(99,71,255)', 'rgb(255,99,71)'],
45    }),
46  };
47
48  return (
49    <Animated.View style={[styles.container, bgStyle]}>
50      <Animated.View style={[styles.box, boxStyle]} />
51    </Animated.View>
52  );
53};
54
55export default App;

Josh Martin

React.JS Developer and Maker

contact@cjoshmartin.com

Chicago, IL

Hello, I am Josh, I am a full-stack developer specializing in developing for Web and Mobile in React, React Native, Node.js, and Django. I used to work at Amazon in the advertising sales Performance department as a Frontend Engineer...

I have a degree from Purdue University in Computer Engineering with the use of my degree and passions I can offer support more than just Web and Mobile development. I can assist with any need related to hardware integration with internet-enabled devices or design needs in CAD and manufacturing.


Handmade by @cjoshmartin, with Django, Next.js and Wagtail (©2025)

Default image for blog post when there is not an image to show

IOS Universal Links with Expo, React Navigation and React Native

read in 7 minutes

Universal links in an expo project do not work exactly as expected when you are using React Navigation. This blog post will help you troubleshoot your issues with setting up Universal Links

Generating ZIP Files with Javascript

read in 2 minutes

I recently created a project called Hinge Trends and apart of the project was to take a set of in memory images, zip those images into a zip file then start a download all from inside the browser. The Library I used for creating the ZIP files is call

Bluetooth Low Energy (BLE) with React Native and Arduino

read in 27 minutes

I have just built my first bluetooth low energy application (BLE) for a client and there are a few gotchas I would like to go over. As well as explain what exactly is Bluetooth Low Energy and how it is different from Bluetooth classic.