Is it possible to do transitions in react native using StyleSheet or styled-components? I am trying the following with no luck.
import React from 'react'
import styled from 'styled-components/native'
import { Text, View, StyleSheet } from 'react-native'
export default class extends React.Component {
render() {
return (
<Wrapper visible={visible}><Text>hello</Text>
)
}
}
const Wrapper = styled.View`
opacity: ${props => props.visible ? 1 : 0};
transition: opacity 1s linear;
`
const styles = StyleSheet.create({
wrapper: {
opacity: 1,
transition:'opacity 1s linear'
}
});