question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

The linear gradient component crashes the app on expo SDK 45.

See original GitHub issue

Steps to Reproduce:

  1. Create an expo managed app with expo init (SDK 45);
  2. Install dripsy and @dripsy/gradient(3.6.0);
  3. Use the gradient component anywhere on the app.

Sample App.tsx


import { Gradient } from "@dripsy/gradient";
import { DripsyProvider, makeTheme } from "dripsy";
import { StatusBar } from "expo-status-bar";
import { Text } from "react-native";

const theme = makeTheme({...});

export default function App() {
  return (
    <DripsyProvider theme={theme}>
      <Gradient
        colors={["green", "blue"]}
        sx={{ flex: 1, alignItems: "center", justifyContent: "center" }}
      >
        <Text>Open up App.tsx to start working on your app!</Text>
        <StatusBar style="auto" />
      </Gradient>
    </DripsyProvider>
  );
}

Expected Result

The app runs crash free

Actual Result

Screen Shot 2022-05-08 at 8 50 58 PM

Screen Shot 2022-05-08 at 9 04 38 PM

Issue Analytics

  • State:closed
  • Created a year ago
  • Comments:24 (13 by maintainers)

github_iconTop GitHub Comments

1reaction
nandorojocommented, May 9, 2022

I think just expo-linear-gradient should suffice, but that works too. I’ll make this a peer dep in a future release. Glad that worked!

0reactions
nandorojocommented, Sep 13, 2022

Can you try upgrading to 3.7.x for both dripsy and the gradient?

Read more comments on GitHub >

github_iconTop Results From Across the Web

expo-linear-gradient is crashing the iOS app #16572 - GitHub
The app will crash. If I remove the expo-linear-gradient component and repeat the same steps, it doesn't crash.
Read more >
linearGradientProps crashes my app - react native
It says in the docs linearGradientProps is only supported in expo so I give up. But the developers seem to mean it should...
Read more >
ErrorRecovery - Expo Documentation
This package only works with the deprecated classic Expo build service. Set arbitrary error recovery props. If your project crashes in production as...
Read more >
IOS (React-native) app crashes in … | Apple Developer Forums
Hi, I am stuck on this for a few days now. Please help. My ReactNative app crashes in TestFlight but seems to work...
Read more >
Getting Constant Crashes on Pages w/ FlatList - Reddit
My app started crashing on the screen with a FlatList when we upgraded ... Hi, which version of expo-linear-gradient u used to fix...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found