miniapp icon indicating copy to clipboard operation
miniapp copied to clipboard

TypeError: Cannot read properties of undefined (reading 'parentPath')

Open OguzhanUmutlu opened this issue 1 year ago • 0 comments

console.log(compile(`export default <div>test</div>`, {...baseOptions}));
C:\Users\HP\IdeaProjects\web-framework\node_modules\jsx-compiler\src\modules\code.js:472
  if (exportComponentPath.parentPath.isExportDefaultDeclaration()) {
                          ^

TypeError: Cannot read properties of undefined (reading 'parentPath')
    at getReplacer (C:\Users\HP\IdeaProjects\web-framework\node_modules\jsx-compiler\src\modules\code.js:472:27)
    at Object.parse (C:\Users\HP\IdeaProjects\web-framework\node_modules\jsx-compiler\src\modules\code.js:83:24)
    at invokeModules (C:\Users\HP\IdeaProjects\web-framework\node_modules\jsx-compiler\src\utils\invokeModules.js:11:25)
    at parse (C:\Users\HP\IdeaProjects\web-framework\node_modules\jsx-compiler\src\parser\index.js:133:3)
    at compile (C:\Users\HP\IdeaProjects\web-framework\node_modules\jsx-compiler\src\index.js:13:18)
    at Object.<anonymous> (C:\Users\HP\IdeaProjects\web-framework\index.js:99:13)
    at Module._compile (node:internal/modules/cjs/loader:1275:14)
    at Module._extensions..js (node:internal/modules/cjs/loader:1329:10)
    at Module.load (node:internal/modules/cjs/loader:1133:32)
    at Module._load (node:internal/modules/cjs/loader:972:12)

Node.js v19.8.1

OguzhanUmutlu avatar Jun 22 '23 07:06 OguzhanUmutlu