jira_clone README

The project's README from github.com/oldboyxx/jira_clone. As one markdown file: README.md.

A simplified Jira clone built with React and Node

Auto formatted with Prettier, tested with Cypress 🎗

Visit the live app | View client | View API

Tech logos

App screenshot

What is this and who is it for 🤷‍♀️

I do React consulting and this is a showcase product I've built in my spare time. It's a very good example of modern, real-world React codebase.

There are many showcase/example React projects out there but most of them are way too simple. I like to think that this codebase contains enough complexity to offer valuable insights to React developers of all skill levels while still being relatively easy to understand.

Features

Setting up development environment 🛠

Running cypress end-to-end tests 🚥

What's missing?

There are features missing from this showcase product which should exist in a real product:

Migrations 🗄

We're currently using TypeORM's synchronize feature which auto creates the database schema on every application launch. It's fine to do this in a showcase product or during early development while the product is not used by anyone, but before going live with a real product, we should introduce migrations.

Proper authentication system 🔐

We currently auto create an auth token and seed a project with issues and users for anyone who visits the API without valid credentials. In a real product we'd want to implement a proper email and password authentication system.

Accessibility ♿

Not all components have properly defined aria attributes, visual focus indicators etc. Most early stage companies tend to ignore this aspect of their product but in many cases they shouldn't, especially once their userbase starts growing.

Unit/Integration tests 🧪

Both Client and API are currently tested through end-to-end Cypress tests. That's good enough for a relatively simple application such as this, even if it was a real product. However, as the app grows in complexity, it might be wise to start writing additional unit/integration tests.

Contributing

I will not be accepting PR's on this repository. Feel free to fork and maintain your own version.

License

MIT


Visit the live app | View client | View API

jira_clone (oldboyxx/jira_clone)

Searching Database…

这是什么东西?一个简化版的 Jira 克隆项目:一个 Web 应用,前端是 React/Babel,后端是 Node/TypeScript 的 API。它由一位 React 顾问开发,目的是展示一个现代、贴近真实场景的 React 代码库,供人阅读和学习,而不是一个正式的生产产品。
它是能跑起来的应用,还是只是示例代码?它是一个可以在本地完整运行的应用:前端和 API 作为两个独立的 npm 进程启动,背后连接你自己的 PostgreSQL 数据库。不过作者仍然把它定位为展示型项目——真正产品所需的一些功能是刻意没有做的。
我怎么把它跑起来?安装 PostgreSQL 并创建一个名为 jiradevelopment 的数据库,克隆仓库,参考 .env.example 创建 /api/.env 并填入你的数据库用户名和密码,然后运行 npm run install-dependencies。在 /api 目录下用 npm start 启动 API,再开一个终端标签页,在 /client 目录下用 npm start 启动前端。
我需要先装好哪些东西?PostgreSQL,以及两个应用都需要的 Node 和 npm——其他都不用。不涉及 Docker 或任何外部服务,你只需要把数据库的连接信息填进 /api/.env 文件。
和真正的 Jira 相比缺了什么?按作者的说法有四点:没有数据库迁移(TypeORM 每次启动都会自动创建表结构)、没有真正的身份验证(任何人不带凭据访问 API 都能拿到令牌和预置的演示数据)、无障碍支持不完整,也没有单元测试和集成测试——只有 Cypress 端到端测试。
这个 React 代码库有哪些值得学习的地方?全部使用带 hooks 的函数式组件,不依赖 redux 或 mobx 的简单本地状态管理,自制的轻量级 UI 组件(如日期选择器、弹窗和表单元素),以及自己搭建的 webpack 配置而非 create-react-app——另外还有一个作者认为是经过验证、可扩展的项目结构。
它是怎么测试的?用 Cypress 做端到端测试。你需要创建第二个名为 jiratest 的数据库,用 npm run start:test 启动 API,然后在 client 目录下运行 npm run test:cypress。
作者为什么要做这个项目?他做 React 咨询工作,觉得大多数展示型的 React 项目都太简单了;他想要一个复杂度足够的代码库,能给各种水平的 React 开发者带来有价值的启发,同时又相对容易看懂。
Creator
oldboyxx
Size
1.9 MB
Stars
11.1K
Updated
CommitOct 20
Age
6y
Commits · 90 Days