zoukankan      html  css  js  c++  java
  • react-native 初始化 各种报错 及 解决方案

    1.Unable to load script from assets 'index.android.bundle'.

    curl -k "http://localhost:8081/index.android.bundle" > android/app/src/main/assets/index.android.bundle

    2.error: bundling failed: Error: Unable to resolve module 'AccessibilityInfo' from

    降级处理

    react-native init AwesomeProject
    cd AwesomeProject
    react-native run-android
    npm uninstall react-native
    npm install --save react-native@0.55.4
    react-native run-android
    npm install --save babel-core@latest babel-loader@latest
    npm uninstall --save-dev babel-preset-react-native
    npm install --save-dev babel-preset-react-native@4.0.0
    react-native run-android

    3.UnableToResolveError: Unable to resolve module ‘***’

    这个问题很常见,原则上是任何npm依赖包都有可能发现这个问题,介绍下解决方案吧

    step one: rm -r node_modules
    step two: npm cache clean --force
    step three: npm install 
    step four: npm start -- --reset-cache

    一般step one, step three, step four就可以解决问题

  • 相关阅读:
    SQL SqlParameter
    C# 迭代器与yield关键字
    ADO.NET调用SQL存储过程
    C# XML
    C# MDI应用程序
    LINQ 基础
    C# 文件操作
    C# 操作注册表
    SQL从SQL SERVER中获取数据库结构信息
    Linux发展史
  • 原文地址:https://www.cnblogs.com/crazycode2/p/9334084.html
Copyright © 2011-2022 走看看