GithubHelp home page GithubHelp logo

eshop's Introduction

eshop

Taro • 云开发电商小程序示例

详细示例说明后续放出

关于 Taro

Taro 是由凹凸实验室打造的一套遵循 React 语法规范的多端统一开发解决方案。使用 Taro,我们可以只书写一套代码,再通过 Taro 的编译工具,将源代码分别编译出可以在不同端(字节跳动小程序、微信小程序、百度智能小程序、支付宝小程序、QQ 小程序、跨应用、H5、App 端等)运行的代码。同时 Taro 还提供开箱即用的语法检测和自动补全等功能,有效地提升了开发体验和开发效率。

Taro 作为 凹凸实验室 的主要开源产品之一,在 github 上拥有 20,000+ star, Taro 在业界获得广泛的关注。

关于云开发

文章中的几个数据集的模拟数据,已上传至 cloud/doc 中,可根据需要自行导入。

云函数的代码存放在 cloud/functions 中,代码是按模块进行分割,每个模块有一个入口文件和一些执行具体逻辑的文件。

关于云函数

在使用你自己的云函数环境时,需要将云函数初始化换成你小程序的云环境。有以下几个地方需要注意:

  • src/app.js
  • cloud/functions 下每个云函数里的 index.js
  • project.config.json 里的 appid 需要换成你的小程序的 appid
// src/app.js
async componentDidMount () {
  Taro.cloud.init({
    env: 'xxyyzz', // 换成你的云函数环境
    traceUser: true // 是否要捕捉每个用户的访问记录。设置为true,用户可在管理端看到用户访问记录
  })
}

项目示例

项目流程图

首页

商详

购物车

订单

eshop's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

eshop's Issues

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.