moti: Issues after upgrading to 0.12 - broken on web

Hi @nandorojo ,

thanks for your AMAZING library. You’ve built something amazing here for the community.

I just upgraded to 0.12 and everything I’ve build which was working fine, is broken right now. I am a bit stuck to understand what happened.

I have a dead simple fadeIn animation (a MotiView with a bunch of unanimated childrens)

index.js:1 The above error occurred in the <ForwardRef(Moti)> component:
Mapper.js:33 Uncaught TypeError: Cannot convert undefined or null to object
    at Function.keys (<anonymous>)
    at extractMutables (Mapper.js:33)
    at Mapper.js:30
    at Array.forEach (<anonymous>)
    at extractMutables (Mapper.js:30)
    at Mapper.extractMutablesFromArray (Mapper.js:38)
    at new Mapper (Mapper.js:8)
    at JSReanimated.startMapper (JSReanimated.js:61)
    at startMapper (core.js:233)
    at Hooks.js:449

After downgrading to 0.11, everything works as expected.

I don’t see any API changes, so I am curious what’s broken right now. Any clue?

      <ScrollLock isActive={lockActive}>
        <MotiView
          style={styles.container}
          from={{ opacity: 0 }}
          animate={{ opacity: 1 }}
          transition={{ type: "timing", duration: 400 }}
        >
            <Text style={styles.title}>{t("global:welcome")}</Text>
            <Text style={styles.subtitle}>{t("welcome:introtext")}</Text>

            <View style={styles.buttonContainer}>
              <StyledButton
                onPress={() => navigation.push("Register")}
                text={t("welcome:start tasting")}
              />
            </View>
        </MotiView>
      </ScrollLock>

Sorry, thats not a really helpful example, but from my perspective, it just breaks no matter what I do.

Even a single

        <MotiView
          style={styles.container}
          from={{ opacity: 0 }}
          animate={{ opacity: 1 }}
          transition={{ type: "timing", duration: 400 }}
        ></MotiView>

is enough to cause the error. Expo Web. Not breaking on iOS or Android.

About this issue

  • Original URL
  • State: closed
  • Created 3 years ago
  • Comments: 15 (9 by maintainers)

Most upvoted comments

@nandorojo thanks for your quick investigation and fix. I can confirm it is working!

Okay I think I found the line breaking it. Investigating further.

Screen Shot 2021-09-01 at 10 26 53 AM

I see this. Haven’t seen this error in ages. Will investigate.

I am seeing this on web too.