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

请问sourcePath: 'cloud'是什么文件夹 #6

Open
misternian opened this issue Apr 13, 2022 · 1 comment
Open

请问sourcePath: 'cloud'是什么文件夹 #6

misternian opened this issue Apr 13, 2022 · 1 comment

Comments

@misternian
Copy link

我在官方文档里并没有看见这个文件夹

谢谢

@toknT
Copy link
Owner

toknT commented Jun 22, 2022

@misternian

这段是别人贡献的目测应该他是用到了云函数,taro打包时不打包云函数的代码所以另外再同步下吧. (云函数我也只知道没用过看到issue后学习了点可能说错)

  • 1 在自己仓库里创建了个名字叫"cloud"的目录
  • 2 在project.config.json里配置cloudfunctionRoot值为"cloud"(微信文档里"快速开始"那里看到截图里用的值是 "cloudfunctions" 就要配置成 sourcePath: 'cloudfunctions')
  • 3 修改在"cloud"下的函数
  • 4 修改小程序代码用taro调用云函数
  • 4 taro打包完成后,激活插件去同步小程序代码到win目录下后再同步云函数代码到win目录下
  • 5 在win下预览

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants