3.0.16版本,build:rn 报Error: 不存在编译平台 rn



  • package.json
    {
    "name": "demo2",
    "version": "1.0.0",
    "private": true,
    "description": "test",
    "templateInfo": {
    "name": "default",
    "typescript": false,
    "css": "none"
    },
    "scripts": {
    "build:weapp": "taro build --type weapp",
    "build:swan": "taro build --type swan",
    "build:alipay": "taro build --type alipay",
    "build:tt": "taro build --type tt",
    "build:h5": "taro build --type h5",
    "build:rn": "taro build --type rn",
    "build:qq": "taro build --type qq",
    "build:jd": "taro build --type jd",
    "build:quickapp": "taro build --type quickapp",
    "dev:weapp": "npm run build:weapp -- --watch",
    "dev:swan": "npm run build:swan -- --watch",
    "dev:alipay": "npm run build:alipay -- --watch",
    "dev:tt": "npm run build:tt -- --watch",
    "dev:h5": "npm run build:h5 -- --watch",
    "dev:rn": "npm run build:rn -- --watch",
    "dev:qq": "npm run build:qq -- --watch",
    "dev:jd": "npm run build:jd -- --watch",
    "dev:quickapp": "npm run build:quickapp -- --watch"
    },
    "browserslist": [
    "last 3 versions",
    "Android >= 4.1",
    "ios >= 8"
    ],
    "author": "",
    "dependencies": {
    "@babel/runtime": "^7.7.7",
    "@tarojs/components": "3.0.16",
    "@tarojs/runtime": "3.0.16",
    "@tarojs/taro": "3.0.16",
    "vue": "^3.0.0"
    },
    "devDependencies": {
    "@types/webpack-env": "^1.13.6",
    "@tarojs/mini-runner": "3.0.16",
    "@babel/core": "^7.8.0",
    "@tarojs/webpack-runner": "3.0.16",
    "babel-preset-taro": "3.0.16",
    "@vue/compiler-sfc": "^3.0.0",
    "vue-loader": "^16.0.0-beta.8",
    "eslint-plugin-vue": "^7.0.0",
    "eslint-config-taro": "3.0.16",
    "eslint": "^6.8.0",
    "stylelint": "9.3.0"
    }
    }



  • 本机要安装ios 或者安卓的对应开发和编译环境。如果什么都没有,就报错。
    另外你可以先看看文档。



  • xcode 和as都有装了。对于编译来讲,把taro项目编译成rn项目,原生环境不是必须的。
    1.34版本是没有问题的。2x,和3x都有问题。这也没有人维护么?


登录后回复