GithubHelp home page GithubHelp logo

haixiangyan / jest-tutorial-example Goto Github PK

View Code? Open in Web Editor NEW
88.0 2.0 13.0 301 KB

🃏《Jest 实践指南》的配套项目

Home Page: http://github.yanhaixiang.com/jest-tutorial/

License: MIT License

JavaScript 25.03% TypeScript 74.31% HTML 0.40% Less 0.11% Shell 0.15%
jest testing typescript

jest-tutorial-example's Introduction

🃏《Jest 实践指南》(配套项目)

Coverage Status

更多关于 Jest 的实践内容请查看 《Jest 实践指南》

jest-tutorial-example's People

Contributors

haixiangyan avatar

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  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

jest-tutorial-example's Issues

跟着教程走到 `引入 React(纯配置)`这一章节,配置好后启动`webpack`报错

从开始的章节一直到引入 React(纯配置)这一章节,按文章内容配置
启动项目会报错,在 win10 和 apple m1 monterey 复现
复现demo: https://github.com/GOWxx/jest-study-example-for-gowxx/tree/repro/webpack_react
在此项目此分支repro/webpack_react下载代码
运行命令
npm install
npm run start
即可看见报错, 报错如下

image

直接拿配套项目
https://github.com/haixiangyan/jest-tutorial-example
package.json 替换都不行,还需要替换 package-lock.json 然后删除 node_modules 重新安装,才能正常运行

User下的index.test.ts测试文件测试失败

报错Unexpected token ,. Expected this, import, async, function, [ for array literal, { for object literal, @ for decorator, function, class, null, true, false, number, bigint, string, regexp, `
│ for template literal, (, or an identifier

代码和仓库里的一模一样
image
image

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.