From cb32e4f40a8ef43a04043e3c0e58dedb8afb04ee Mon Sep 17 00:00:00 2001 From: AlexNg Date: Sun, 24 Mar 2024 08:49:45 +0800 Subject: [PATCH 01/10] chore: Add editorconfiguration --- .editorconfig | 13 +++++++++++++ 1 file changed, 13 insertions(+) create mode 100644 .editorconfig diff --git a/.editorconfig b/.editorconfig new file mode 100644 index 00000000..d8af035f --- /dev/null +++ b/.editorconfig @@ -0,0 +1,13 @@ +# EditorConfig is awesome: https://EditorConfig.org + +# top-most EditorConfig file +root = true + +# Unix-style newlines with a newline ending every file +[*] +end_of_line = lf +trim_trailing_whitespace = true +insert_final_newline = true +charset = utf-8 +indent_size = 2 +indent_style = space From bef3b739f2ffadcc38de55005f11707cc0cec0a6 Mon Sep 17 00:00:00 2001 From: AlexNg Date: Sun, 24 Mar 2024 09:23:30 +0800 Subject: [PATCH 02/10] chore: Add single quotes --- .editorconfig | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.editorconfig b/.editorconfig index d8af035f..a44d79d7 100644 --- a/.editorconfig +++ b/.editorconfig @@ -11,3 +11,5 @@ insert_final_newline = true charset = utf-8 indent_size = 2 indent_style = space +quote_type = single + From ed3c48a7e1f0b6ad4a64bd0e1f507a2c658e237c Mon Sep 17 00:00:00 2001 From: AlexNg Date: Sun, 24 Mar 2024 09:23:52 +0800 Subject: [PATCH 03/10] chore(deps): Add prettier linting --- package-lock.json | 18 +++++++++++++++++- package.json | 3 ++- 2 files changed, 19 insertions(+), 2 deletions(-) diff --git a/package-lock.json b/package-lock.json index 18eadf09..08d26929 100644 --- a/package-lock.json +++ b/package-lock.json @@ -10,7 +10,8 @@ "shared/*" ], "devDependencies": { - "concurrently": "^8.2.2" + "concurrently": "^8.2.2", + "prettier": "^3.2.5" }, "engines": { "node": "21.6.1", @@ -3509,6 +3510,21 @@ "node": ">= 0.8.0" } }, + "node_modules/prettier": { + "version": "3.2.5", + "resolved": "https://registry.npmjs.org/prettier/-/prettier-3.2.5.tgz", + "integrity": "sha512-3/GWa9aOC0YeD7LUfvOG2NiDyhOWRvt1k+rcKhOuYnMY24iiCphgneUfJDyFXd6rZCAnuLBv6UeAULtrhT/F4A==", + "dev": true, + "bin": { + "prettier": "bin/prettier.cjs" + }, + "engines": { + "node": ">=14" + }, + "funding": { + "url": "https://github.com/prettier/prettier?sponsor=1" + } + }, "node_modules/process-nextick-args": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-2.0.1.tgz", diff --git a/package.json b/package.json index dfadbc5d..2697d443 100644 --- a/package.json +++ b/package.json @@ -18,7 +18,8 @@ "lint:fix": "npm run lint:fix --workspaces --if-present" }, "devDependencies": { - "concurrently": "^8.2.2" + "concurrently": "^8.2.2", + "prettier": "^3.2.5" }, "engines": { "node": "21.6.1", From 95afc0ef3f1641ed24288cbf2b1fd868763c810f Mon Sep 17 00:00:00 2001 From: AlexNg Date: Sun, 24 Mar 2024 09:24:23 +0800 Subject: [PATCH 04/10] chore: Update linting scripts --- package.json | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/package.json b/package.json index 2697d443..deea0139 100644 --- a/package.json +++ b/package.json @@ -12,10 +12,14 @@ "test": "npm run test --workspaces --if-present", "lint:client": "npm run lint --workspace=client", "lint:server": "npm run lint --workspace=server", - "lint": "npm run lint --workspaces --if-present", + "lint:eslint": "npm run lint --workspaces --if-present", + "lint:prettier": "prettier --check .", + "lint": "npm run lint:eslint && npm run lint:prettier", "lint:client:fix": "npm run lint:fix --workspace=client", "lint:server:fix": "npm run lint:fix --workspace=server", - "lint:fix": "npm run lint:fix --workspaces --if-present" + "lint:eslint:fix": "npm run lint:fix --workspaces --if-present", + "lint:prettier:fix": "prettier --write .", + "lint:fix": "npm run lint:eslint:fix && npm run lint:prettier:fix" }, "devDependencies": { "concurrently": "^8.2.2", From 9807af5ff0bbccd6230cac516429d3ee0d5a0da0 Mon Sep 17 00:00:00 2001 From: AlexNg Date: Sun, 24 Mar 2024 09:25:45 +0800 Subject: [PATCH 05/10] style: Linting --- .github/CODESTYLE.md | 41 ++++---- .github/CODE_OF_CONDUCT.md | 24 ++--- .github/CONTRIBUTING.md | 6 +- .github/ISSUE_TEMPLATE/1-bug-report.md | 37 +++---- .github/ISSUE_TEMPLATE/2-failing-test.md | 22 ++--- .github/ISSUE_TEMPLATE/3-docs-bug.md | 17 ++-- .github/ISSUE_TEMPLATE/4-feature-request.md | 22 ++--- .../ISSUE_TEMPLATE/5-enhancement-request.md | 22 ++--- .github/ISSUE_TEMPLATE/6-security-report.md | 33 +++---- .github/ISSUE_TEMPLATE/7-question-support.md | 15 ++- .github/PULL_REQUEST_TEMPLATE.md | 19 +--- .github/SECURITY.md | 2 +- .github/dependabot.yml | 12 +-- .github/labeler.yml | 14 +-- .github/release-drafter.yml | 34 +++---- .github/settings.yml | 52 +++++----- .github/workflows/first-time-contributor.yml | 4 +- .github/workflows/labeler.yml | 2 +- CITATION.cff | 2 +- README.md | 99 ++++++++----------- client/.eslintrc.cjs | 4 +- client/README.md | 2 +- client/index.html | 2 +- client/postcss.config.js | 2 +- client/src/components/footer.tsx | 18 ++-- client/src/components/navbar.tsx | 18 ++-- client/src/main.tsx | 40 ++++---- client/src/pages/404.tsx | 9 +- client/src/pages/root.tsx | 10 +- client/src/pages/route-map.tsx | 21 ++-- client/tailwind.config.ts | 10 +- client/tsconfig.json | 14 +-- client/vite.config.ts | 8 +- server/index.ts | 13 ++- server/tsconfig.json | 9 +- shared/api-types/.eslintrc.json | 13 +-- shared/api-types/tsconfig.json | 4 +- 37 files changed, 287 insertions(+), 389 deletions(-) diff --git a/.github/CODESTYLE.md b/.github/CODESTYLE.md index 6d96f3fc..8aa162ef 100644 --- a/.github/CODESTYLE.md +++ b/.github/CODESTYLE.md @@ -1,4 +1,5 @@ # Code Style + The following is a general guide on how to style your work so that the project remains consistent throughout all files. Please read this document in it's entirety and refer to it throughout the development of your contribution. @@ -7,9 +8,8 @@ and refer to it throughout the development of your contribution. 2. [Commit Message Guidelines](#commit-message-guidelines) 3. [Markdown Guidelines](#markdown-guidelines) - - ## General Guidelines + Listed is a example class used demonstrate general rules you should follow throughout the development of your contribution. - Docstrings are to follow {{DOCSTRING_FORMAT}} @@ -19,40 +19,39 @@ Listed is a example class used demonstrate general rules you should follow throu code example ``` - - ## Markdown Guidelines + Currently, documentation for this project resides in markdown files. - - Headings are to be separated with 3 lines - - Use of HTML comments is appreciated - - Use of HTML is permitted - - [reference style links](https://www.markdownguide.org/basic-syntax/#reference-style-links) are not required by are appreciated - - Exceedingly long lines are to be broken - - The indents are to be 4 spaces + +- Headings are to be separated with 3 lines +- Use of HTML comments is appreciated +- Use of HTML is permitted +- [reference style links](https://www.markdownguide.org/basic-syntax/#reference-style-links) are not required by are appreciated +- Exceedingly long lines are to be broken +- The indents are to be 4 spaces ```markdown + # Section + Lorem ipsum dolor sit amet, consectetur adipiscing elit, -sed do eiusmod tempor incididunt ut labore et dolore -magna aliqua. Ut enim ad minim veniam, quis nostrud -exercitation ullamco laboris nisi ut aliquip ex ea -commodo consequat. Duis aute irure dolor in -reprehenderit in voluptate velit esse cillum dolore eu -fugiat nulla pariatur. Excepteur sint occaecat cupidatat -non proident, sunt in culpa qui officia deserunt mollit +sed do eiusmod tempor incididunt ut labore et dolore +magna aliqua. Ut enim ad minim veniam, quis nostrud +exercitation ullamco laboris nisi ut aliquip ex ea +commodo consequat. Duis aute irure dolor in +reprehenderit in voluptate velit esse cillum dolore eu +fugiat nulla pariatur. Excepteur sint occaecat cupidatat +non proident, sunt in culpa qui officia deserunt mollit anim id est laborum. found [Lorem Ipsum Generator] - - # Section 2 +
  • Apple
  • Orange
  • Pineapple
- - [Lorem Ipsum Generator]: https://loremipsum.io/generator/ ``` diff --git a/.github/CODE_OF_CONDUCT.md b/.github/CODE_OF_CONDUCT.md index 1631c6b9..4e51d7c3 100644 --- a/.github/CODE_OF_CONDUCT.md +++ b/.github/CODE_OF_CONDUCT.md @@ -17,23 +17,23 @@ diverse, inclusive, and healthy community. Examples of behavior that contributes to a positive environment for our community include: -* Demonstrating empathy and kindness toward other people -* Being respectful of differing opinions, viewpoints, and experiences -* Giving and gracefully accepting constructive feedback -* Accepting responsibility and apologizing to those affected by our mistakes, +- Demonstrating empathy and kindness toward other people +- Being respectful of differing opinions, viewpoints, and experiences +- Giving and gracefully accepting constructive feedback +- Accepting responsibility and apologizing to those affected by our mistakes, and learning from the experience -* Focusing on what is best not just for us as individuals, but for the +- Focusing on what is best not just for us as individuals, but for the overall community Examples of unacceptable behavior include: -* The use of sexualized language or imagery, and sexual attention or +- The use of sexualized language or imagery, and sexual attention or advances of any kind -* Trolling, insulting or derogatory comments, and personal or political attacks -* Public or private harassment -* Publishing others' private information, such as a physical or email +- Trolling, insulting or derogatory comments, and personal or political attacks +- Public or private harassment +- Publishing others' private information, such as a physical or email address, without their explicit permission -* Other conduct which could reasonably be considered inappropriate in a +- Other conduct which could reasonably be considered inappropriate in a professional setting ## Enforcement Responsibilities @@ -105,7 +105,7 @@ Violating these terms may lead to a permanent ban. ### 4. Permanent Ban **Community Impact**: Demonstrating a pattern of violation of community -standards, including sustained inappropriate behavior, harassment of an +standards, including sustained inappropriate behavior, harassment of an individual, or aggression toward or disparagement of classes of individuals. **Consequence**: A permanent ban from any sort of public interaction within @@ -124,4 +124,4 @@ enforcement ladder](https://github.com/mozilla/diversity). For answers to common questions about this code of conduct, see the FAQ at https://www.contributor-covenant.org/faq. Translations are available at -https://www.contributor-covenant.org/translations. \ No newline at end of file +https://www.contributor-covenant.org/translations. diff --git a/.github/CONTRIBUTING.md b/.github/CONTRIBUTING.md index 40124bd5..605c8d91 100644 --- a/.github/CONTRIBUTING.md +++ b/.github/CONTRIBUTING.md @@ -5,8 +5,6 @@ email, or any other method with the owners of this repository before making a ch Please note we have a [code of conduct](CODE_OF_CONDUCT.md); please follow it in all your interactions with the project. - - ## Pull Request Process 1. Ensure any install or build dependencies are removed before the end of the layer when doing a @@ -17,11 +15,9 @@ Please note we have a [code of conduct](CODE_OF_CONDUCT.md); please follow it in 4. You may merge the Pull Request once you have the sign-off of two other developers, or if you do not have permission to do that, you may request the second reviewer to merge it for you. - - ## Issue Report Process 1. Go to the project's issues. 2. Select the template that better fits your issue. 3. Read the instructions carefully and write within the template guidelines. -4. Submit it and wait for support. \ No newline at end of file +4. Submit it and wait for support. diff --git a/.github/ISSUE_TEMPLATE/1-bug-report.md b/.github/ISSUE_TEMPLATE/1-bug-report.md index 4b9fd934..af6d116f 100644 --- a/.github/ISSUE_TEMPLATE/1-bug-report.md +++ b/.github/ISSUE_TEMPLATE/1-bug-report.md @@ -1,19 +1,18 @@ --- -name: "Bug Report" -about: "Report an issue to help the project improve." -title: "[Bug] " -labels: "Type: Bug" +name: 'Bug Report' +about: 'Report an issue to help the project improve.' +title: '[Bug] ' +labels: 'Type: Bug' assignees: caffeine-addictt - --- # Bug report + Your issue may already be reported! Please check out our [active issues](https://github.com/caffeine-addictt/nyp_y2_fullstack/issues) before creating one. - - ## Expected Behavior + - - ## Current Behavior + - - ## Is this a regression? + - - ## Possible Solution + - - ## Steps to Reproduce (for bugs) + + 1. 2. 3. 4. - - ## Context + - - ## Your Environment + -* Version used: -* Operating System and version (desktop or mobile): \ No newline at end of file + +- Version used: +- Operating System and version (desktop or mobile): diff --git a/.github/ISSUE_TEMPLATE/2-failing-test.md b/.github/ISSUE_TEMPLATE/2-failing-test.md index 7b1cf193..7c970bf5 100644 --- a/.github/ISSUE_TEMPLATE/2-failing-test.md +++ b/.github/ISSUE_TEMPLATE/2-failing-test.md @@ -1,40 +1,36 @@ --- -name: "Failing Test" -about: "Report failing tests or CI jobs." -title: "[Test] " -labels: "Type: Test" +name: 'Failing Test' +about: 'Report failing tests or CI jobs.' +title: '[Test] ' +labels: 'Type: Test' assignees: caffeine-addictt - --- # Failing Test + Your issue may already be reported! Please check out our [active issues](https://github.com/caffeine-addictt/nyp_y2_fullstack/issues) before creating one. - - ## Which Jobs/Tests are Failing? -* - +- ## Reason for Failure + - - ## Media Prove + - - ## Additional Context + diff --git a/.github/ISSUE_TEMPLATE/3-docs-bug.md b/.github/ISSUE_TEMPLATE/3-docs-bug.md index 75d234e3..11ed82c0 100644 --- a/.github/ISSUE_TEMPLATE/3-docs-bug.md +++ b/.github/ISSUE_TEMPLATE/3-docs-bug.md @@ -1,26 +1,24 @@ --- -name: "Documentation or README.md issue report" +name: 'Documentation or README.md issue report' about: "Report an issue in the project's documentation or README.md file." -title: "" -labels: "Documentation" +title: '' +labels: 'Documentation' assignees: caffeine-addictt - --- # Documentation Issue Report + Your issue may already be reported! Please check out our [active issues](https://github.com/caffeine-addictt/nyp_y2_fullstack/issues) before creating one. - - ## Describe the Bug + - - ## Steps to Reproduce + diff --git a/.github/ISSUE_TEMPLATE/4-feature-request.md b/.github/ISSUE_TEMPLATE/4-feature-request.md index b419f445..a5579842 100644 --- a/.github/ISSUE_TEMPLATE/4-feature-request.md +++ b/.github/ISSUE_TEMPLATE/4-feature-request.md @@ -1,19 +1,18 @@ --- -name: "Feature Request" -about: "Suggest an idea or possible new feature for this project." -title: "" -labels: "Type: Feature" +name: 'Feature Request' +about: 'Suggest an idea or possible new feature for this project.' +title: '' +labels: 'Type: Feature' assignees: caffeine-addictt - --- # Feature Request + Your issue may already be reported! Please check out our [active issues](https://github.com/caffeine-addictt/nyp_y2_fullstack/issues) before creating one. - - ## Is Your Feature Request Related to an Issue? + - - ## Describe the Solution You'd Like + - - ## Describe Alternatives You've Considered + - - ## Additional Context + diff --git a/.github/ISSUE_TEMPLATE/5-enhancement-request.md b/.github/ISSUE_TEMPLATE/5-enhancement-request.md index 09768f82..d176e0e0 100644 --- a/.github/ISSUE_TEMPLATE/5-enhancement-request.md +++ b/.github/ISSUE_TEMPLATE/5-enhancement-request.md @@ -1,19 +1,18 @@ --- -name: "Enhancement Request" -about: "Suggest an enhancement for this project. Improve an existing feature" -title: "" -labels: "Type: Enhancement" +name: 'Enhancement Request' +about: 'Suggest an enhancement for this project. Improve an existing feature' +title: '' +labels: 'Type: Enhancement' assignees: caffeine-addictt - --- # Enhancement Request + Your issue may already be reported! Please check out our [active issues](https://github.com/caffeine-addictt/nyp_y2_fullstack/issues) before creating one. - - ## Is Your Enhancement Request Related to an Issue? + - - ## Describe the Solution You'd Like + - - ## Describe Alternatives You've Considered + - - ## Additional Context + diff --git a/.github/ISSUE_TEMPLATE/6-security-report.md b/.github/ISSUE_TEMPLATE/6-security-report.md index b445f3a1..a1436086 100644 --- a/.github/ISSUE_TEMPLATE/6-security-report.md +++ b/.github/ISSUE_TEMPLATE/6-security-report.md @@ -1,10 +1,9 @@ --- -name: "Security Report" -about: "Report an issue to help the project improve." -title: "" -labels: "Type: Security" +name: 'Security Report' +about: 'Report an issue to help the project improve.' +title: '' +labels: 'Type: Security' assignees: caffeine-addictt - --- # Security Report + Your issue may already be reported! Please check out our [active issues](https://github.com/caffeine-addictt/nyp_y2_fullstack/issues) before creating one. - - ## Describe the Security Issue + - - ## Steps to Reproduce + - - ## Expected Behavior + - - ## Media Prove + - - ## Additional Context + - - ### Your Environment + -* Version used: -* Operating System and version (desktop or mobile): \ No newline at end of file + +- Version used: +- Operating System and version (desktop or mobile): diff --git a/.github/ISSUE_TEMPLATE/7-question-support.md b/.github/ISSUE_TEMPLATE/7-question-support.md index 0d83d10f..77e1c906 100644 --- a/.github/ISSUE_TEMPLATE/7-question-support.md +++ b/.github/ISSUE_TEMPLATE/7-question-support.md @@ -1,20 +1,17 @@ --- -name: "Question or Support Request" -about: "Questions and requests for support." -title: "" -labels: ["Type: Question", "help wanted"] +name: 'Question or Support Request' +about: 'Questions and requests for support.' +title: '' +labels: ['Type: Question', 'help wanted'] assignees: caffeine-addictt - --- # Question or Support Request - - - ## Describe your question or ask for support + -* \ No newline at end of file +- diff --git a/.github/PULL_REQUEST_TEMPLATE.md b/.github/PULL_REQUEST_TEMPLATE.md index cbb29ca3..181b7563 100644 --- a/.github/PULL_REQUEST_TEMPLATE.md +++ b/.github/PULL_REQUEST_TEMPLATE.md @@ -22,13 +22,8 @@ - [ ] Breaking Change - [ ] Documentation Update - - ## Description - - - ## Related Tickets & Documents + - [ ] My code follows the code style of this project. - [ ] My change requires a change to the documentation. -- [ ] I have updated the documentation accordingly. \ No newline at end of file +- [ ] I have updated the documentation accordingly. diff --git a/.github/SECURITY.md b/.github/SECURITY.md index 3ac832f3..50065f1c 100644 --- a/.github/SECURITY.md +++ b/.github/SECURITY.md @@ -8,4 +8,4 @@ To report a security issue, go to the project's issues and create a new issue us Read the instructions of this issue template carefully, and if your report could leak data or might expose how to gain access to a restricted area or break the system, please email [contact@ngjx.org](mailto:contact@ngjx.org) and include the word "SECURITY" in the subject line. -We'll endeavour to respond quickly and keep you updated throughout the process. \ No newline at end of file +We'll endeavour to respond quickly and keep you updated throughout the process. diff --git a/.github/dependabot.yml b/.github/dependabot.yml index 92995f52..04f278bf 100644 --- a/.github/dependabot.yml +++ b/.github/dependabot.yml @@ -5,13 +5,13 @@ version: 2 updates: - - package-ecosystem: "github-actions" + - package-ecosystem: 'github-actions' # Workflow files stored in the default location of `.github/workflows`. (You don't need to specify `/.github/workflows` for `directory`. You can use `directory: "/"`.) - directory: "/" + directory: '/' schedule: - interval: "weekly" + interval: 'weekly' - - package-ecosystem: "npm" # See documentation for possible values - directory: "/" # Location of package manifests + - package-ecosystem: 'npm' # See documentation for possible values + directory: '/' # Location of package manifests schedule: - interval: "weekly" + interval: 'weekly' diff --git a/.github/labeler.yml b/.github/labeler.yml index fa4dd291..c0f28451 100644 --- a/.github/labeler.yml +++ b/.github/labeler.yml @@ -3,25 +3,25 @@ Documentation: - changed-files: - - any-glob-to-any-file: [docs/**, "**/*.{md,mdx}"] - - all-globs-to-all-files: "!**/*.{yaml,yml}" + - any-glob-to-any-file: [docs/**, '**/*.{md,mdx}'] + - all-globs-to-all-files: '!**/*.{yaml,yml}' -"Type: Test": +'Type: Test': - changed-files: - any-glob-to-any-file: [tests/**, ./*test*] -"Type: CI": +'Type: CI': - changed-files: - any-glob-to-any-file: [.github/workflows/**] -"Scope: Server": +'Scope: Server': - changed-files: - any-glob-to-any-file: [server/**] -"Scope: Client": +'Scope: Client': - changed-files: - any-glob-to-any-file: [client/**] -"Scope: Utilities": +'Scope: Utilities': - changed-files: - any-glob-to-any-file: [shared/**] diff --git a/.github/release-drafter.yml b/.github/release-drafter.yml index 03f3266b..62572e9b 100644 --- a/.github/release-drafter.yml +++ b/.github/release-drafter.yml @@ -1,5 +1,5 @@ -name-template: "v$RESOLVED_VERSION" -tag-template: "v$RESOLVED_VERSION" +name-template: 'v$RESOLVED_VERSION' +tag-template: 'v$RESOLVED_VERSION' template: | # What's Changed @@ -8,33 +8,33 @@ template: | **Full Changelog**: https://github.com/$OWNER/$REPOSITORY/compare/$PREVIOUS_TAG...v$RESOLVED_VERSION categories: - - title: "New" - label: "Type: Feature" + - title: 'New' + label: 'Type: Feature' - - title: "Bug Fixes" - label: "Type: Bug" + - title: 'Bug Fixes' + label: 'Type: Bug' - - title: "Improvements" - label: "Type: Enhancement" + - title: 'Improvements' + label: 'Type: Enhancement' - - title: "Other changes" + - title: 'Other changes' - - title: "Documentation" - label: "Documentation" + - title: 'Documentation' + label: 'Documentation' collapse-after: 5 version-resolver: major: labels: - - "Type: Breaking" + - 'Type: Breaking' minor: labels: - - "Type: Feature" + - 'Type: Feature' patch: labels: - - "Type: Bug" - - "Documentation" - - "Type: Security" + - 'Type: Bug' + - 'Documentation' + - 'Type: Security' exclude-labels: - - "Skip-Changelog" + - 'Skip-Changelog' diff --git a/.github/settings.yml b/.github/settings.yml index 0d283931..94f581b2 100644 --- a/.github/settings.yml +++ b/.github/settings.yml @@ -8,71 +8,71 @@ # To counteract this, please block force pushing and enable "Require CODE OWNER Approval" for Pull Requests to the main branch. labels: - - name: "Type: CI" + - name: 'Type: CI' color: 54b2ff description: A problem or enhancement related to continuous integration. - - name: "Type: Breaking" + - name: 'Type: Breaking' color: a90000 description: A problem or enhancement related to a breaking change. - - name: "Type: Bug" + - name: 'Type: Bug' color: e80c0c description: Something isn't working as expected. - - name: "Type: Enhancement" + - name: 'Type: Enhancement' color: 54b2ff description: Suggest an improvement for an existing feature. - - name: "Type: Feature" + - name: 'Type: Feature' color: 54b2ff description: Suggest a new feature. - - name: "Type: Security" + - name: 'Type: Security' color: fbff00 description: A problem or enhancement related to a security issue. - - name: "Type: Question" + - name: 'Type: Question' color: 9309ab description: Request for information. - - name: "Type: Test" + - name: 'Type: Test' color: ce54e3 description: A problem or enhancement related to a test. - - name: "Status: Awaiting Review" + - name: 'Status: Awaiting Review' color: 24d15d description: Ready for review. - - name: "Status: WIP" + - name: 'Status: WIP' color: 07b340 description: Currently being worked on. - - name: "Status: Waiting" + - name: 'Status: Waiting' color: 38C968 description: Waiting on something else to be ready. - - name: "Status: Stale" + - name: 'Status: Stale' color: 66b38a description: Has had no activity for some time. - - name: "Duplicate" + - name: 'Duplicate' color: EB862D description: Duplicate of another issue. - - name: "Invalid" + - name: 'Invalid' color: faef50 description: This issue doesn't seem right. - - name: "Priority: High +" + - name: 'Priority: High +' color: ff008c description: Task is considered higher-priority. - - name: "Priority: Low -" + - name: 'Priority: Low -' color: 690a34 description: Task is considered lower-priority. - - name: "Documentation" + - name: 'Documentation' color: 2fbceb description: An issue/change with the documentation. @@ -80,38 +80,38 @@ labels: color: C8D9E6 description: Reported issue is working as intended. - - name: "3rd party issue" + - name: '3rd party issue' color: e88707 description: This issue might be caused by a 3rd party script/package/other reasons - - name: "Os: Windows" + - name: 'Os: Windows' color: AEB1C2 description: Is Windows-specific - - name: "Os: Mac" + - name: 'Os: Mac' color: AEB1C2 description: Is Mac-specific - - name: "Os: Linux" + - name: 'Os: Linux' color: AEB1C2 description: Is Linux-specific - - name: "Skip-Changelog" + - name: 'Skip-Changelog' color: AEB1C2 description: Skip changelog in release tag - - name: "help wanted" + - name: 'help wanted' color: 008672 description: Help wanted - - name: "Scope: Server" + - name: 'Scope: Server' color: B08EC1 description: This change affects the server. - - name: "Scope: Client" + - name: 'Scope: Client' color: B08EC1 description: This change affects the client. - - name: "Scope: Utilities" + - name: 'Scope: Utilities' color: B08EC1 description: This change affects utilities. diff --git a/.github/workflows/first-time-contributor.yml b/.github/workflows/first-time-contributor.yml index 74c9e712..09635f4d 100644 --- a/.github/workflows/first-time-contributor.yml +++ b/.github/workflows/first-time-contributor.yml @@ -14,5 +14,5 @@ jobs: - uses: actions/first-interaction@v1 with: repo-token: ${{ secrets.GITHUB_TOKEN }} - issue-message: "Thank you for your first contribution! 🥳" - pr-message: "Thank you for your first contribution! 🥳" + issue-message: 'Thank you for your first contribution! 🥳' + pr-message: 'Thank you for your first contribution! 🥳' diff --git a/.github/workflows/labeler.yml b/.github/workflows/labeler.yml index e421977d..40486194 100644 --- a/.github/workflows/labeler.yml +++ b/.github/workflows/labeler.yml @@ -12,4 +12,4 @@ jobs: steps: - uses: actions/labeler@v5 with: - repo-token: "${{ secrets.GITHUB_TOKEN }}" + repo-token: '${{ secrets.GITHUB_TOKEN }}' diff --git a/CITATION.cff b/CITATION.cff index 96bb5be9..f6f6af6b 100644 --- a/CITATION.cff +++ b/CITATION.cff @@ -11,7 +11,7 @@ identifiers: cff-version: 1.2.0 date-released: yyyy-mm-dd keywords: - - + - license: MIT message: If you use this software, please cite it using these metadata. repository-code: https://github.com/caffeine-addictt/nyp_y2_fullstack diff --git a/README.md b/README.md index 86a46692..ebbb175a 100644 --- a/README.md +++ b/README.md @@ -12,8 +12,6 @@ - -
@@ -33,8 +31,6 @@

- -
Table of Contents @@ -74,9 +70,8 @@
- - + ## About The Project ![Social Card](images/socialcard.png) @@ -85,29 +80,26 @@ later

(back to top)

- - ### Built with These are the major frameworks and libraries used in this project. -* ![Vite](https://img.shields.io/badge/vite-%23646CFF.svg?style=for-the-badge&logo=vite&logoColor=white) -* ![React](https://img.shields.io/badge/react-%2320232a.svg?style=for-the-badge&logo=react&logoColor=%2361DAFB) -* ![Express.js](https://img.shields.io/badge/express.js-%23404d59.svg?style=for-the-badge&logo=express&logoColor=%2361DAFB) -* ![TypeScript](https://img.shields.io/badge/typescript-%23007ACC.svg?style=for-the-badge&logo=typescript&logoColor=white) -* ![TailwindCSS](https://img.shields.io/badge/tailwindcss-%2338B2AC.svg?style=for-the-badge&logo=tailwind-css&logoColor=white) -* ![ESLint](https://img.shields.io/badge/ESLint-4B3263?style=for-the-badge&logo=eslint&logoColor=white) -* ![Nodemon](https://img.shields.io/badge/NODEMON-%23323330.svg?style=for-the-badge&logo=nodemon&logoColor=%BBDEAD) -* ![NPM](https://img.shields.io/badge/NPM-%23CB3837.svg?style=for-the-badge&logo=npm&logoColor=white) -* ![NodeJS](https://img.shields.io/badge/node.js-6DA55F?style=for-the-badge&logo=node.js&logoColor=white) -* ![Vercel](https://img.shields.io/badge/vercel-%23000000.svg?style=for-the-badge&logo=vercel&logoColor=white) -* ![GitHub Actions](https://img.shields.io/badge/github%20actions-%232671E5.svg?style=for-the-badge&logo=githubactions&logoColor=white) +- ![Vite](https://img.shields.io/badge/vite-%23646CFF.svg?style=for-the-badge&logo=vite&logoColor=white) +- ![React](https://img.shields.io/badge/react-%2320232a.svg?style=for-the-badge&logo=react&logoColor=%2361DAFB) +- ![Express.js](https://img.shields.io/badge/express.js-%23404d59.svg?style=for-the-badge&logo=express&logoColor=%2361DAFB) +- ![TypeScript](https://img.shields.io/badge/typescript-%23007ACC.svg?style=for-the-badge&logo=typescript&logoColor=white) +- ![TailwindCSS](https://img.shields.io/badge/tailwindcss-%2338B2AC.svg?style=for-the-badge&logo=tailwind-css&logoColor=white) +- ![ESLint](https://img.shields.io/badge/ESLint-4B3263?style=for-the-badge&logo=eslint&logoColor=white) +- ![Nodemon](https://img.shields.io/badge/NODEMON-%23323330.svg?style=for-the-badge&logo=nodemon&logoColor=%BBDEAD) +- ![NPM](https://img.shields.io/badge/NPM-%23CB3837.svg?style=for-the-badge&logo=npm&logoColor=white) +- ![NodeJS](https://img.shields.io/badge/node.js-6DA55F?style=for-the-badge&logo=node.js&logoColor=white) +- ![Vercel](https://img.shields.io/badge/vercel-%23000000.svg?style=for-the-badge&logo=vercel&logoColor=white) +- ![GitHub Actions](https://img.shields.io/badge/github%20actions-%232671E5.svg?style=for-the-badge&logo=githubactions&logoColor=white)

(back to top)

- - + ## Getting Started This is an example of how you can set up your project locally. @@ -115,8 +107,8 @@ To get a local copy up and running follow these simple example steps. ### Prerequisites -* Node v21.6.1 -* NPM v10.4.0 +- Node v21.6.1 +- NPM v10.4.0 ### Installation @@ -127,7 +119,7 @@ _Below is an example of how you can install the project locally._ ```sh git clone https://github.com/caffeine-addictt/nyp_y2_fullstack cd nyp_y2_fullstack - ``` +``` #### 2. Install Dependencies @@ -143,9 +135,8 @@ npm run dev

(back to top)

- - + ## Documentation You can find the front-end app in the `client/` directory and the back-end API in the `server/` directory. @@ -210,9 +201,8 @@ npm uninstall vite -w client # Uninstalls the vite package in the client workspa

(back to top)

- - + ## Contributing Contributions are what make the open source community such an amazing place to learn, inspire, and create. Any contributions you make are **greatly appreciated**. ( ˶ˆᗜˆ˵ ) @@ -228,24 +218,23 @@ Don't forget to give the project a star! Thanks again!

(back to top)

- - + ### Commit Message Guidelines When committing, commit messages are prefixed with one of the following depending on the type of change made. -* `feat:` when a new feature is introduced with the changes. -* `fix:` when a bug fix has occurred. -* `chore:` for changes that do not relate to a fix or feature and do not modify _source_ or _tests_. (like updating dependencies) -* `refactor:` for refactoring code that neither fixes a bug nor adds a feature. -* `docs:` when changes are made to documentation. -* `style:` when changes that do not affect the code, but modify formatting. -* `test:` when changes to tests are made. -* `perf:` for changes that improve performance. -* `ci:` for changes that affect CI. -* `build:` for changes that affect the build system or external dependencies. -* `revert:` when reverting changes. +- `feat:` when a new feature is introduced with the changes. +- `fix:` when a bug fix has occurred. +- `chore:` for changes that do not relate to a fix or feature and do not modify _source_ or _tests_. (like updating dependencies) +- `refactor:` for refactoring code that neither fixes a bug nor adds a feature. +- `docs:` when changes are made to documentation. +- `style:` when changes that do not affect the code, but modify formatting. +- `test:` when changes to tests are made. +- `perf:` for changes that improve performance. +- `ci:` for changes that affect CI. +- `build:` for changes that affect the build system or external dependencies. +- `revert:` when reverting changes. A parenthesis can be placed after the type of change to indicate the scope of the change. Below list some example commit messages. @@ -259,17 +248,16 @@ See the [open issues](https://github.com/caffeine-addictt/nyp_y2_fullstack/issue

(back to top)

- - + ### Pull Request Guidelines When creating a pull request, please use our PR template and follow the checklist provided. We require the following CI to pass before the PR can be merged: -* Linting -* Tests +- Linting +- Tests #### Linting locally @@ -281,34 +269,31 @@ You can test locally by running `npm run test` in the root of the project.

(back to top)

- - + ## License Distributed under the MIT License. See [LICENSE.txt](./LICENSE.txt) for more information.

(back to top)

- - + ## Contact Jun Xiang - [contact@ngjx.org](mailto:contact@ngjx.org)

(back to top)

- - + ## Acknowledgments -* [Repository Template](https://github.com/caffeine-addictt/template) -* [Choose an Open Source License](https://choosealicense.com) -* [GitHub Emoji Cheat Sheet](https://www.webpagefx.com/tools/emoji-cheat-sheet) -* [Malven's Flexbox Cheatsheet](https://flexbox.malven.co/) -* [Malven's Grid Cheatsheet](https://grid.malven.co/) -* [Img Shields](https://shields.io) +- [Repository Template](https://github.com/caffeine-addictt/template) +- [Choose an Open Source License](https://choosealicense.com) +- [GitHub Emoji Cheat Sheet](https://www.webpagefx.com/tools/emoji-cheat-sheet) +- [Malven's Flexbox Cheatsheet](https://flexbox.malven.co/) +- [Malven's Grid Cheatsheet](https://grid.malven.co/) +- [Img Shields](https://shields.io)

(back to top)

diff --git a/client/.eslintrc.cjs b/client/.eslintrc.cjs index 7128a8a5..9e3ebd81 100644 --- a/client/.eslintrc.cjs +++ b/client/.eslintrc.cjs @@ -5,7 +5,7 @@ module.exports = { 'eslint:recommended', 'plugin:@typescript-eslint/recommended', 'plugin:react-hooks/recommended', - 'plugin:tailwindcss/recommended' + 'plugin:tailwindcss/recommended', ], ignorePatterns: ['dist', '.eslintrc.cjs'], parser: '@typescript-eslint/parser', @@ -16,4 +16,4 @@ module.exports = { { allowConstantExport: true }, ], }, -} +}; diff --git a/client/README.md b/client/README.md index 0d6babed..9d0b4bcd 100644 --- a/client/README.md +++ b/client/README.md @@ -22,7 +22,7 @@ export default { project: ['./tsconfig.json', './tsconfig.node.json'], tsconfigRootDir: __dirname, }, -} +}; ``` - Replace `plugin:@typescript-eslint/recommended` to `plugin:@typescript-eslint/recommended-type-checked` or `plugin:@typescript-eslint/strict-type-checked` diff --git a/client/index.html b/client/index.html index 715eb7cb..ac010324 100644 --- a/client/index.html +++ b/client/index.html @@ -4,7 +4,7 @@ - + Fullstack diff --git a/client/postcss.config.js b/client/postcss.config.js index 2e7af2b7..2aa7205d 100644 --- a/client/postcss.config.js +++ b/client/postcss.config.js @@ -3,4 +3,4 @@ export default { tailwindcss: {}, autoprefixer: {}, }, -} +}; diff --git a/client/src/components/footer.tsx b/client/src/components/footer.tsx index fd4e47e0..2db37624 100644 --- a/client/src/components/footer.tsx +++ b/client/src/components/footer.tsx @@ -1,14 +1,8 @@ -import * as React from 'react' -import { Location } from 'react-router-dom' +import * as React from 'react'; +import { Location } from 'react-router-dom'; - -export type FooterProps = { location: Location, isAdmin: boolean } +export type FooterProps = { location: Location; isAdmin: boolean }; const Footer = (props: FooterProps): React.ReactNode => { - return ( -
- Footer at {props.location.pathname} -
- ) -} -export default Footer - + return
Footer at {props.location.pathname}
; +}; +export default Footer; diff --git a/client/src/components/navbar.tsx b/client/src/components/navbar.tsx index b91722b1..3b388430 100644 --- a/client/src/components/navbar.tsx +++ b/client/src/components/navbar.tsx @@ -1,14 +1,8 @@ -import * as React from 'react' -import { Location } from 'react-router-dom' +import * as React from 'react'; +import { Location } from 'react-router-dom'; - -export type NavbarProps = { location: Location, isAdmin: boolean } +export type NavbarProps = { location: Location; isAdmin: boolean }; const Navbar = (props: NavbarProps): React.ReactNode => { - return ( - - ) -} -export default Navbar - + return ; +}; +export default Navbar; diff --git a/client/src/main.tsx b/client/src/main.tsx index ecb66589..28a85b40 100644 --- a/client/src/main.tsx +++ b/client/src/main.tsx @@ -1,44 +1,46 @@ -import * as React from 'react' -import ReactDOM from 'react-dom/client' -import { useLocation, Route, Routes, BrowserRouter } from 'react-router-dom' -import '@styles/globals.css' +import * as React from 'react'; +import ReactDOM from 'react-dom/client'; +import { useLocation, Route, Routes, BrowserRouter } from 'react-router-dom'; +import '@styles/globals.css'; -import { Helmet } from 'react-helmet' -import routes, { type RouteDetails } from '@pages/route-map' +import { Helmet } from 'react-helmet'; +import routes, { type RouteDetails } from '@pages/route-map'; // Components -import Navbar from '@components/navbar' -import Footer from '@components/footer' +import Navbar from '@components/navbar'; +import Footer from '@components/footer'; - -export const WrappedComponent = ({ component: Component, title }: RouteDetails): JSX.Element => ( +export const WrappedComponent = ({ + component: Component, + title, +}: RouteDetails): JSX.Element => ( <> {title} -) +); export const Layout = (): JSX.Element => { - const location = useLocation() + const location = useLocation(); return ( -
+
-
+
- {Object.entries(routes).map(([path, details]) => + {Object.entries(routes).map(([path, details]) => ( } /> - )} + ))}
- ) -} + ); +}; ReactDOM.createRoot(document.getElementById('root')!).render( @@ -46,4 +48,4 @@ ReactDOM.createRoot(document.getElementById('root')!).render( , -) +); diff --git a/client/src/pages/404.tsx b/client/src/pages/404.tsx index 9ac19dd9..5a0bde5a 100644 --- a/client/src/pages/404.tsx +++ b/client/src/pages/404.tsx @@ -1,11 +1,10 @@ -import type { PageComponent } from '@pages/route-map' - +import type { PageComponent } from '@pages/route-map'; const NotFound: PageComponent = () => { return (

Page Not Found

- ) -} -export default NotFound + ); +}; +export default NotFound; diff --git a/client/src/pages/root.tsx b/client/src/pages/root.tsx index 657a6c96..8614c580 100644 --- a/client/src/pages/root.tsx +++ b/client/src/pages/root.tsx @@ -1,8 +1,6 @@ -import type { PageComponent } from '@pages/route-map' - +import type { PageComponent } from '@pages/route-map'; const RootPage: PageComponent = () => { - return <>hi -} -export default RootPage - + return <>hi; +}; +export default RootPage; diff --git a/client/src/pages/route-map.tsx b/client/src/pages/route-map.tsx index 952be987..db3595be 100644 --- a/client/src/pages/route-map.tsx +++ b/client/src/pages/route-map.tsx @@ -1,23 +1,20 @@ // This is the root-level final page mapping -import * as React from 'react' +import * as React from 'react'; // Page imports -import NotFound from '@pages/404' -import RootPage from '@pages/root' +import NotFound from '@pages/404'; +import RootPage from '@pages/root'; +export type PathStr = '*' | '/' | `/${string}`; +export type PageComponent = () => React.JSX.Element; -export type PathStr = '*' | '/' | `/${string}` -export type PageComponent = () => React.JSX.Element - -export type RouteDetails = { component: PageComponent, title: string } -export type RouteMap = Record - +export type RouteDetails = { component: PageComponent; title: string }; +export type RouteMap = Record; const routes: RouteMap = { '*': { component: NotFound, title: 'Page Not Found' }, '/': { component: RootPage, title: 'Home' }, -} - -export default routes +}; +export default routes; diff --git a/client/tailwind.config.ts b/client/tailwind.config.ts index 277a789b..57d3ab20 100644 --- a/client/tailwind.config.ts +++ b/client/tailwind.config.ts @@ -1,13 +1,9 @@ -import type { Config } from 'tailwindcss' +import type { Config } from 'tailwindcss'; export default { - content: [ - './index.html', - './src/**/*.{js,jsx,ts,tsx}' - ], + content: ['./index.html', './src/**/*.{js,jsx,ts,tsx}'], theme: { extend: {}, }, plugins: [], -} satisfies Config - +} satisfies Config; diff --git a/client/tsconfig.json b/client/tsconfig.json index 942ded82..5bd8052d 100644 --- a/client/tsconfig.json +++ b/client/tsconfig.json @@ -2,11 +2,7 @@ "compilerOptions": { "target": "ES2020", "useDefineForClassFields": true, - "lib": [ - "ES2020", - "DOM", - "DOM.Iterable" - ], + "lib": ["ES2020", "DOM", "DOM.Iterable"], "module": "ESNext", "skipLibCheck": true, /* Bundler mode */ @@ -23,14 +19,10 @@ "noFallthroughCasesInSwitch": true, /* Import aliases */ "paths": { - "@*": [ - "./src/*" - ] + "@*": ["./src/*"] } }, - "include": [ - "src" - ], + "include": ["src"], "references": [ { "path": "./tsconfig.node.json" diff --git a/client/vite.config.ts b/client/vite.config.ts index 2d1c613d..48825ddb 100644 --- a/client/vite.config.ts +++ b/client/vite.config.ts @@ -1,8 +1,8 @@ -import { defineConfig } from 'vite' -import react from '@vitejs/plugin-react-swc' -import tsconfigPaths from 'vite-tsconfig-paths' +import { defineConfig } from 'vite'; +import react from '@vitejs/plugin-react-swc'; +import tsconfigPaths from 'vite-tsconfig-paths'; // https://vitejs.dev/config/ export default defineConfig({ plugins: [tsconfigPaths(), react()], -}) +}); diff --git a/server/index.ts b/server/index.ts index 8c9573cc..05961506 100644 --- a/server/index.ts +++ b/server/index.ts @@ -1,10 +1,9 @@ -import express from 'express' -const app = express() +import express from 'express'; +const app = express(); -app.get('/', (_, res) => res.status(200).send('Hello World!')) -app.get('/api', (_, res) => res.status(200).send('This is an API!')) +app.get('/', (_, res) => res.status(200).send('Hello World!')); +app.get('/api', (_, res) => res.status(200).send('This is an API!')); -app.listen(3000, () => console.log('Example app listening on port 3000!')) - -module.exports = app +app.listen(3000, () => console.log('Example app listening on port 3000!')); +module.exports = app; diff --git a/server/tsconfig.json b/server/tsconfig.json index c8b000ae..0b16a3d1 100644 --- a/server/tsconfig.json +++ b/server/tsconfig.json @@ -11,13 +11,8 @@ "skipLibCheck": true, "baseUrl": ".", "paths": { - "*": [ - "node_modules/*", - "api/types/*" - ] + "*": ["node_modules/*", "api/types/*"] } }, - "include": [ - "./api/**/*" - ], + "include": ["./api/**/*"] } diff --git a/shared/api-types/.eslintrc.json b/shared/api-types/.eslintrc.json index 5b272768..81c6dfe8 100644 --- a/shared/api-types/.eslintrc.json +++ b/shared/api-types/.eslintrc.json @@ -1,14 +1,7 @@ { "root": true, - "extends": [ - "eslint:recommended", - "plugin:@typescript-eslint/recommended" - ], + "extends": ["eslint:recommended", "plugin:@typescript-eslint/recommended"], "parser": "@typescript-eslint/parser", - "plugins": [ - "@typescript-eslint" - ], - "ignorePatterns": [ - "dist" - ] + "plugins": ["@typescript-eslint"], + "ignorePatterns": ["dist"] } diff --git a/shared/api-types/tsconfig.json b/shared/api-types/tsconfig.json index b2f9a250..9ecba6d5 100644 --- a/shared/api-types/tsconfig.json +++ b/shared/api-types/tsconfig.json @@ -2,9 +2,7 @@ "compilerOptions": { "module": "commonjs", "target": "ES2020", - "lib": [ - "ES2020" - ], + "lib": ["ES2020"], "strict": true, "composite": true, "declarationMap": true, From 882402b471be1fcb31f72cb16df352cbd58495a4 Mon Sep 17 00:00:00 2001 From: AlexNg Date: Sun, 24 Mar 2024 09:26:54 +0800 Subject: [PATCH 06/10] style: Remove ignoring MD012 --- README.md | 3 --- 1 file changed, 3 deletions(-) diff --git a/README.md b/README.md index ebbb175a..b56c533f 100644 --- a/README.md +++ b/README.md @@ -1,9 +1,6 @@ - - - From eb8045c3266df57334008a6e7fcdc1263efd34ef Mon Sep 17 00:00:00 2001 From: AlexNg Date: Sun, 24 Mar 2024 09:27:53 +0800 Subject: [PATCH 07/10] docs: Add preview deployment requirement --- README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/README.md b/README.md index b56c533f..27955c93 100644 --- a/README.md +++ b/README.md @@ -255,6 +255,7 @@ We require the following CI to pass before the PR can be merged: - Linting - Tests +- Client and Server Preview Deployments #### Linting locally From 00c955fcd5c8cc7aeecc5d0a353f8a92f7a1df2e Mon Sep 17 00:00:00 2001 From: AlexNg Date: Sun, 24 Mar 2024 09:28:21 +0800 Subject: [PATCH 08/10] docs: Move open issues --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 27955c93..0206d73c 100644 --- a/README.md +++ b/README.md @@ -213,6 +213,8 @@ Don't forget to give the project a star! Thanks again! 4. Push to the Branch (`git push origin feature/AmazingFeature`) 5. Open a Pull Request +See the [open issues](https://github.com/caffeine-addictt/nyp_y2_fullstack/issues) for a full list of proposed features (and known issues). +

(back to top)

@@ -241,8 +243,6 @@ git commit -m "revert(server): Fall back to old typing" git commit -m "docs: Moved README.md" ``` -See the [open issues](https://github.com/caffeine-addictt/nyp_y2_fullstack/issues) for a full list of proposed features (and known issues). -

(back to top)

From 7a4c3f6d4ea814c9e0960afa454757933c506e69 Mon Sep 17 00:00:00 2001 From: AlexNg Date: Sun, 24 Mar 2024 09:29:01 +0800 Subject: [PATCH 09/10] docs: Conform to MD026 --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 0206d73c..9002bccb 100644 --- a/README.md +++ b/README.md @@ -188,7 +188,7 @@ npm run build:server # Build the server We use NPM workspaces to share updates to the client and server packages. You can use the `-w` flag to run a command in a workspace with the path. -#### For example: +#### For example ```sh npm i tailwindcss -w server # Installs the tailwindcss package in the server workspace From 24c7ad33d867478be86073ada83e03b8c843c2c4 Mon Sep 17 00:00:00 2001 From: AlexNg Date: Sun, 24 Mar 2024 09:31:02 +0800 Subject: [PATCH 10/10] docs: Update docs on linting --- README.md | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/README.md b/README.md index 9002bccb..67325107 100644 --- a/README.md +++ b/README.md @@ -156,15 +156,17 @@ npm run dev:server # Run development server on server ### Linting ```sh -npm run lint # Run linting on all packages -npm run lint:client # Run linting on client -npm run lint:server # Run linting on server +npm run lint # Run ESLint and Prettier on the whole project +npm run lint:eslint # Run ESLint on all packages +npm run lint:client # Run ESLint on client +npm run lint:server # Run ESLint on server ``` ```sh -npm run lint:fix # Run linting on all packages and fix any linting errors -npm run lint:client:fix # Run linting on client and fix any linting errors -npm run lint:server:fix # Run linting on server and fix any linting errors +npm run lint:fix # Run ESLint and Prettier on the whole project +npm run lint:eslint:fix # Run ESLint on all packages and fix any linting errors +npm run lint:client:fix # Run ESLint on client and fix any linting errors +npm run lint:server:fix # Run ESLint on server and fix any linting errors ``` ### Testing