Skip to content

Commit

Permalink
Upgrade yarn, typescript, and all packages to latest version in range (
Browse files Browse the repository at this point in the history
…#8)

* Upgrade yarn and typescript

* Run yarn dedupe --strategy highest

* skip lib check

* Run `yarn upgrade-interactive` and upgrade to latest in range

* Run `pre-commit run -a` and clean out generated files

* Upgrade prettier and eslint

* Use newer node versions on CI

* Only use node 18 and 20
  • Loading branch information
dmattia authored Dec 4, 2023
1 parent 402da9d commit 0827ec4
Show file tree
Hide file tree
Showing 845 changed files with 16,625 additions and 16,335 deletions.
5 changes: 0 additions & 5 deletions .eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,6 @@ module.exports = {

/**
* We prefer to use types instead of interfaces
*
* @see https://www.notion.so/transcend/Use-Type-instead-of-Interface-b3868d0885724b6894647018323a57b2
*/
'@typescript-eslint/prefer-interface': 0,
Expand All @@ -98,7 +97,6 @@ module.exports = {

/**
* We use a custom pre-commit for import orders
*
* @see pre_commit_hooks/ordered_imports.js
*/
'import/order': 0,
Expand Down Expand Up @@ -144,22 +142,19 @@ module.exports = {

/**
* Type signatures should be combined if possible:
*
* @see https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/unified-signatures.md
*/
'@typescript-eslint/unified-signatures': ['error'],

/**
* Group overrides next to each other
*
* @see https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/adjacent-overload-signatures.md
*/
'@typescript-eslint/adjacent-overload-signatures': ['error'],

/**
* Explicitly specify return types to functions. This improves type safety
* and also allows compiler to optimize
*
* @see https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/explicit-function-return-type.md
* @see https://www.notion.so/transcend/4ef10ad243b746d9b2a84f8bb4a1b01a?v=8eb2ce8c21d54b43a916e7f93a563950&p=36b3bd33e054443084d2759537e6423b
*/
Expand Down
19 changes: 11 additions & 8 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,13 +18,14 @@ jobs:
strategy:
matrix:
os: [ubuntu-latest]
node-version: [12.x, 14.x]
node-version: [18.x, 20.x]
steps:
- uses: actions/checkout@v2
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node-version }}
- run: npm install -g "[email protected]"
- run: yarn test

run-pre-commits:
Expand All @@ -34,10 +35,11 @@ jobs:
with:
fetch-depth: 100 # need the history to do a changed files check below (source, origin)
- uses: actions/setup-python@v2
- name: Use Node.js 14.x
- name: Use Node.js 18.x
uses: actions/setup-node@v1
with:
node-version: 14.x
node-version: 18.x
- run: npm install -g "[email protected]"
- uses: pre-commit/[email protected]
with:
extra_args: --source ${{ github.event.pull_request.base.sha || 'HEAD~1' }} --origin ${{ github.event.pull_request.head.sha || 'HEAD' }}
Expand All @@ -46,11 +48,12 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Use Node.js 14.x
- name: Use Node.js 18.x
uses: actions/setup-node@v1
with:
node-version: 14.x
- run: yarn pnpify depcheck
node-version: 18.x
- run: npm install -g "[email protected]"
- run: yarn depcheck

build-to-npm:
if: github.ref == 'refs/heads/main'
Expand All @@ -64,7 +67,7 @@ jobs:
uses: actions/checkout@v2
- uses: actions/setup-node@v2
with:
node-version: '14.x'
node-version: '18.x'
- name: Configure NPM authentication
run: |
yarn config set npmAlwaysAuth true
Expand All @@ -84,7 +87,7 @@ jobs:
uses: actions/checkout@v2
- uses: actions/setup-node@v2
with:
node-version: '14.x'
node-version: '18.x'
- name: Configure Github Packages authentication
run: |
yarn config set npmAlwaysAuth true
Expand Down
Loading

0 comments on commit 0827ec4

Please sign in to comment.