aidenybai / million

Optimize React performance and make your React 70% faster in minutes, not months.
https://million.dev
MIT License
15.94k stars 559 forks source link

TypeError: (0 , million_react_server__WEBPACK_IMPORTED_MODULE_2__.compiledBlock) is not a function #964

Closed jahirfiquitiva closed 4 months ago

jahirfiquitiva commented 5 months ago

What version of million are you using?

3.0.3

Are you using an SSR adapter? If so, which one?

Vercel

What package manager are you using?

yarn

What operating system are you using?

Mac

What browser are you using?

Arc

Describe the Bug

I'm getting this error in my project:

 ⨯ src/components/atoms/logo.tsx (10:30) @ _props
 ⨯ TypeError: (0 , million_react_server__WEBPACK_IMPORTED_MODULE_2__.compiledBlock) is not a function
    at eval (webpack-internal:///(rsc)/./src/components/atoms/logo.tsx:12:83)
    at Object.(rsc)/./src/components/atoms/logo.tsx (/Users/jahir/dev/jahir/website/.next/server/app/(home)/page.js:807:1)
    at __webpack_require__ (/Users/jahir/dev/jahir/website/.next/server/webpack-runtime.js:33:42)
    at eval (webpack-internal:///(rsc)/./src/components/molecules/footer/index.tsx:7:80)
    at Object.(rsc)/./src/components/molecules/footer/index.tsx (/Users/jahir/dev/jahir/website/.next/server/app/(home)/page.js:886:1)
    at __webpack_require__ (/Users/jahir/dev/jahir/website/.next/server/webpack-runtime.js:33:42)
    at eval (webpack-internal:///(rsc)/./src/app/layout.tsx:12:86)
    at Object.(rsc)/./src/app/layout.tsx (/Users/jahir/dev/jahir/website/.next/server/app/(home)/page.js:708:1)
    at Function.__webpack_require__ (/Users/jahir/dev/jahir/website/.next/server/webpack-runtime.js:33:42)
    at eq (/Users/jahir/dev/jahir/website/node_modules/next/dist/compiled/next-server/webpack:/next/dist/esm/server/lib/app-dir-module.js:10:17)
    at tr (/Users/jahir/dev/jahir/website/node_modules/next/dist/compiled/next-server/webpack:/next/dist/esm/lib/metadata/resolve-metadata.js:238:26)
    at tn (/Users/jahir/dev/jahir/website/node_modules/next/dist/compiled/next-server/webpack:/next/dist/esm/lib/metadata/resolve-metadata.js:290:5)
    at tu (/Users/jahir/dev/jahir/website/node_modules/next/dist/compiled/next-server/webpack:/next/dist/esm/lib/metadata/resolve-metadata.js:476:35)
    at /Users/jahir/dev/jahir/website/node_modules/next/dist/compiled/next-server/webpack:/next/dist/esm/lib/metadata/metadata.js:38:69 {
  digest: '3623295010',
  page: '/'
}
   8 |   fgClassName?: string;
   9 | }
> 10 | const Logo_1 = _compiledBlock(_props => <svg viewBox={'0 0 32 32'} role={'presentation'} aria-hidden={'true'} {..._props.v0} className={_props.v1}>
     |                              ^
  11 |       <path className={_props.v2} fill={_props.v3} d={'M25.4,3.9C22.8,1.3,19.4,0,16,0S9.2,1.3,6.6,3.9C1.5,9,1.5,17.5,6.6,22.6L16,32l9.4-9.4C30.5,17.5,30.5,9,25.4,3.9z'}></path>
  12 |       <path className={_props.v4} d={'M10,9.1V8h5.8c-0.7,0.5-1.3,1.3-1.4,2.2h-3.3C10.5,10.2,10,9.7,10,9.1z M21.5,14c0,0.6-0.5,1.1-1.1,1.1h-2.2c-0.6,0-1.1,0.5-1.1,1.1v1.6c0,1.8-1.5,3.3-3.3,3.3s-3.3-1.5-3.3-3.3v-2.7h1.1c0.6,0,1.1,0.5,1.1,1.1v1.6c0,0.6,0.5,1.1,1.1,1.1s1.1-0.5,1.1-1.1v-1.6c0-1.8,1.5-3.3,3.3-3.3h3.3L21.5,14z M22,9.1c0,0.6-0.5,1.1-1.1,1.1h-2.7c-0.6,0-1.1,0.5-1.1,1.1v1.1c-0.9,0.2-1.7,0.7-2.2,1.4v-2.6c0-1.8,1.5-3.3,3.3-3.3H22L22,9.1z'}></path>
  13 |     </svg>, {
 ○ Compiling /_error ...

What's the expected result?

Build successful

Link to Minimal Reproducible Example

https://github.com/jahirfiquitiva/jahir.dev/pull/73

Participation

github-actions[bot] commented 5 months ago

Thanks for opening this issue! A maintainer will review it soon.

0x221A commented 5 months ago

Related: https://github.com/aidenybai/million/issues/958

github-actions[bot] commented 4 months ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs within the next 7 days.