Failure to import Rive artboard to Framer
I'm getting an error message in framer after pasting in the Framer code to a new code component. Here is the code:
import React, { useEffect } from "react"
import { addPropertyControls } from "framer"
import _ from "@rive-app/react-canvas"
import RiveComponent, {
componentName, propertyControls
} from "https://rive.app/api/s/o_mamCFRNkm_A-YWCQlRFA/framer/"
/**
* @framerSupportedLayoutWidth any-prefer-fixed
* @framerSupportedLayoutHeight any-prefer-fixed
*/
export default RiveComponent as React.ComponentType
RiveComponent.displayName = componentName
addPropertyControls(RiveComponent, propertyControls)
Here is the console output from Framer:
T20:01:59.313Z warn: [modules-runtime] Error in 'codeFile/Hero_Rive.tsx': Error: Unable to resolve specifier '@rive-app/react-canvas' imported from https://rive.app/api/s/o_mamCFRNkm_A-YWCQlRFA/framer/ at a0 (https://app.framerstatic.com/es-module-shims-U3QXTE66.js:4:534) at Re (https://app.framerstatic.com/es-module-shims-U3QXTE66.js:4:503) at resolveHook (https://app.framerstatic.com/chunk-ZZP2CTCY.js:1:4091) at resolve (https://project-a4zcyjyyaw6ch3aqaooc.framercanvas.com/s/app.a4439fa23b28fcd421eb703f8344773e3f81ed5a/preview-next.html?target=code-editor-preview-web&mode=dark:222:33) at i0 (https://app.framerstatic.com/es-module-shims-U3QXTE66.js:4:130) at https://app.framerstatic.com/es-module-shims-U3QXTE66.js:9:1364 at Array.map (<anonymous>) at https://app.framerstatic.com/es-module-shims-U3QXTE66.js:9:1266
Please help me! This is for an urgent project
Would you mind sharing a bit more information about what you are trying to do? Would it also be possible if we could take a look at the file?
Adding to
See that you also logged a ticket with Support. Feel free to reply here or in that ticket.
https://www.loom.com/share/1a4b201ed9214ac4b61d59a4014c44d5?sid=9bdcaf9f-b437-4b85-afae-ee518043555c
Here's a loom of my attempt.
https://rive.app/s/PJ9mBMBn7EGIqJWPUUWxsw/
Here's a share link to the current Rive file.
I'm hoping to expose the triggers I have set up in the rive file so that I can switch tabs in the state machine using a tab component in Framer.