We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
The viteconfig.ts:
import { defineConfig } from 'vite' import react from '@vitejs/plugin-react' import jsxRefresh from "@vitejs/plugin-react-refresh" import { narrowSolidPlugin } from "@merged/react-solid/plugin" // https://vitejs.dev/config/ export default defineConfig({ plugins: [react(), narrowSolidPlugin({ include: /\/src\/solid/ }), jsxRefresh({exclude: /\/src\/solid\//}) ], })
App.jsx
import { Solid } from '@merged/react-solid' import { Dot } from './solid/Dot.jsx' function App() { return ( <Solid component={Dot} id={"abc"} x={19} y={5} /> ) } export default App
solid/Dot.jsx
import { spring } from "motion"; import { Motion } from "@motionone/solid"; import { mapScale, springConfig } from '../constants' export function Dot(props) { return ( <Motion> style={{ width: '20px', height: '20px', background: "#ff6d6c", "border-radius": '50%' }} animate={{ x: mapScale.width(props.x), y: mapScale.height(props.y) }} transition={{ easing: spring(springConfig) }} > <span>RID:{props.id}</span> </Motion> ) }
The App renders something as below:
style=[object Object]animate=[object Object]transition=[object Object]>RID:abc
anything could've been wrong?
The text was updated successfully, but these errors were encountered:
No branches or pull requests
The viteconfig.ts:
App.jsx
solid/Dot.jsx
The App renders something as below:
anything could've been wrong?
The text was updated successfully, but these errors were encountered: