Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

百度小程序预渲染失败 #11376

Closed
neo693 opened this issue Mar 2, 2022 · 3 comments
Closed

百度小程序预渲染失败 #11376

neo693 opened this issue Mar 2, 2022 · 3 comments
Labels
F-react Framework - React question Further information is requested T-swan Target - 编译到百度小程序 V-3 Version - 3.x

Comments

@neo693
Copy link

neo693 commented Mar 2, 2022

相关平台

百度小程序

小程序基础库: 3.420.5
使用框架: React

复现步骤

执行 taro build --type swan 或 taro build --type swan --blended

期望结果

百度小程序正常生成预渲染结果

实际结果

2022/3/2 下午12:07:02 页面 app 预渲染失败:
ReferenceError [Error]: inst is not defined

2022/3/2 下午12:07:02 页面 pages/home/index 预渲染失败:
TypeError [Error]: page.onLoad is not a function

环境信息

 Taro CLI 3.4.0 environment info:
    System:
      OS: macOS 11.6
      Shell: 5.8 - /bin/zsh
    Binaries:
      Node: 14.17.0 - ~/.nvm/versions/node/v14.17.0/bin/node
      Yarn: 1.22.17 - /usr/local/bin/yarn
      npm: 6.14.13 - ~/.nvm/versions/node/v14.17.0/bin/npm
    npmPackages:
      @tarojs/cli: 3.4.2 => 3.4.2 
      @tarojs/components: 3.4.2 => 3.4.2 
      @tarojs/mini-runner: 3.4.2 => 3.4.2 
      @tarojs/react: 3.4.2 => 3.4.2 
      @tarojs/taro: 3.4.2 => 3.4.2 
      @tarojs/webpack-runner: 3.4.2 => 3.4.2 
      babel-preset-taro: 3.4.2 => 3.4.2 
      bbj-taro-runtime:  3.4.2 
      eslint-config-taro: 3.4.2 => 3.4.2 
      react: ^17.0.2 => 17.0.2 


补充信息

阿里小程序打包也报错

@taro-bot2 taro-bot2 bot added F-react Framework - React T-swan Target - 编译到百度小程序 V-3 Version - 3.x labels Mar 2, 2022
@github-actions
Copy link
Contributor

github-actions bot commented Mar 2, 2022

等待热心的小伙伴解决问题中..., 有一些相关的 issues 可能帮助到你!

Thank you so much!

@Chen-jj
Copy link
Contributor

Chen-jj commented Mar 13, 2022

@simons2333 麻烦提供一下 Demo,复现步骤也描述得详细一点

@Chen-jj Chen-jj added the question Further information is requested label Mar 13, 2022
@Chen-jj Chen-jj closed this as completed Oct 17, 2022
@saralee2012
Copy link

请问下百度预渲染失败的问题已经解决么 taro3.6.4版本设置prerender还是报page.onLoad is not a function

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
F-react Framework - React question Further information is requested T-swan Target - 编译到百度小程序 V-3 Version - 3.x
Projects
None yet
Development

No branches or pull requests

3 participants