简体   繁体   English

出现错误:没有要呈现的“App.js”的默认导出

[英]Getting error: No default export of 'App.js' to render

I have the following Snack Expo :我有以下Snack Expo

https://snack.expo.io/r1_WoB744 https://snack.expo.io/r1_WoB744

which is a simplification of the official react-native-paper Snack Expo :这是官方react-native-paper Snack Expo的简化:

https://snack.expo.io/@satya164/github.com-callstack-react-native-paper:example https://snack.expo.io/@satya164/github.com-callstack-react-native-paper:例子

On top of removing all the components except: { BottomNavigationExample, CardExample } I did the following changes:除了删除所有组件之外: { BottomNavigationExample, CardExample }我做了以下更改:

截屏

The I got the above Snack Expo , here the link again:我得到了上面的Snack Expo ,这里再次链接:

https://snack.expo.io/r1_WoB744 https://snack.expo.io/r1_WoB744

My problem is that when running the app on the online simulator I'm getting the error:我的问题是在在线模拟器上运行应用程序时出现错误:

Device: (13:5485) No default export of 'App.js' to render!

I have to say that 2 or 3 days ago this link worked properly.我不得不说 2 或 3 天前这个链接工作正常。

Any idea on how to solve this?关于如何解决这个问题的任何想法?

If possible, please provide back a working Snack Expo .如果可能,请提供一个可用的Snack Expo

Thanks!谢谢!

add following to App.js file将以下内容添加到 App.js 文件

export default App;

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 ./src/index.js 尝试导入错误:“./App.js”不包含默认导出(导入为“App”) - ./src/index.js Attempted import error: './App.js' does not contain a default export (imported as 'App') App.js 的渲染方法出错? 反应原生问题 - Error in render method of App.js? React-Native question 来自solidity合约的app.js文件中的getJSON()出错 - Getting error in getJSON() in app.js file from solidity contract 我定义了组件并使用它 App.js 但出现未定义的错误 - I defined component and used it App.js but getting undefined error 为什么新的expo init会产生“导出默认功能”而不是“导出默认类”? 在App.js中 - Why does a new expo init produce “export default function” rather than “export default class”? in App.js 无法获得Jest和酵素来从我的App.js进行div测试 - Trouble getting Jest and enzyme to render a div test from my App.js 错误提供。在 ReactJS 中渲染不是 function。 App.js 未在 LocalHost 上正常运行 - Error provides .render not a function in ReactJS. App.js is not running properly on LocalHost AngularJS app.js获取URL - Angularjs app.js getting URL 制作待办事项并存储在本地存储中但出现此错误 fetchdata.map is not a function at App (App.js:27:1) - make todo and store in localstorage but getting this error fetchdata.map is not a function at App (App.js:27:1) 在 app.js 中出现此错误,尝试再次运行此代码,但得到相同的错误帮助我 - Got this error in app.js trying to run this code again but getting the same error help me guys
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM