-
Notifications
You must be signed in to change notification settings - Fork 756
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
chore: run eslint and tsc in missing packages #6090
Conversation
|
5e161d9
to
1f2b7d7
Compare
A wrangler prerelease is available for testing. You can install this latest build in your project with: npm install --save-dev https://prerelease-registry.devprod.cloudflare.dev/workers-sdk/runs/9584485005/npm-package-wrangler-6090 You can reference the automatically updated head of this PR with: npm install --save-dev https://prerelease-registry.devprod.cloudflare.dev/workers-sdk/prs/6090/npm-package-wrangler-6090 Or you can use npx https://prerelease-registry.devprod.cloudflare.dev/workers-sdk/runs/9584485005/npm-package-wrangler-6090 dev path/to/script.js Additional artifacts:npx https://prerelease-registry.devprod.cloudflare.dev/workers-sdk/runs/9584485005/npm-package-create-cloudflare-6090 --no-auto-update npm install https://prerelease-registry.devprod.cloudflare.dev/workers-sdk/runs/9584485005/npm-package-cloudflare-kv-asset-handler-6090 npm install https://prerelease-registry.devprod.cloudflare.dev/workers-sdk/runs/9584485005/npm-package-miniflare-6090 npm install https://prerelease-registry.devprod.cloudflare.dev/workers-sdk/runs/9584485005/npm-package-cloudflare-pages-shared-6090 npm install https://prerelease-registry.devprod.cloudflare.dev/workers-sdk/runs/9584485005/npm-package-cloudflare-vitest-pool-workers-6090 Note that these links will no longer work once the GitHub Actions artifact expires.
Please ensure constraints are pinned, and |
Some of our packages didn't have a lint/typecheck rule setup, so I added it. Also fixed a couple of failures along the way. I _didn't_ enable linting for kv-asset-handler because that looks like a bit more work, which we can do later.
1f2b7d7
to
39515d3
Compare
@@ -30,7 +30,6 @@ | |||
"dev:codemod": "node -r esbuild-register scripts/codemodDev.ts", | |||
"check:lint": "eslint .", | |||
"check:type": "tsc", | |||
"lint": "eslint", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
we already have check:lint above this which actually lints the package, this command doesn't do anything
@@ -0,0 +1,4 @@ | |||
module.exports = { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
added this config so I can locally run eslint, but as mentioned it won't do it in CI yet until I fix all the failures
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'll leave it up to you, but in case we are not planning on fixing those failures any time soon, we might want to consider flagging what you said ☝️ with a comment, just in case someone wakes up one day with the urge of using this config 😅 . Again, abs up to you!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I plan on doing it myself soon, filed #6101
@@ -42,6 +42,7 @@ export function useRefreshableIframe( | |||
second.removeEventListener("load", onLoadEvent); | |||
}; | |||
} | |||
// eslint-disable-next-line react-hooks/exhaustive-deps |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this one is a tricky one to fix, excluding it for now
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
do we want to keep track of these somehow as to not forget to properly fix them at some point?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Filed #6101
@@ -69,6 +70,7 @@ export function useRefreshableIframe( | |||
if (src) { | |||
setUrl(src); | |||
} | |||
// eslint-disable-next-line react-hooks/exhaustive-deps |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this one is a tricky one to fix, excluding it for now
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
same question here
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you for putting this up Sunil <3
Followup from #6090, this enables typechecking and linting in kv-asset-handler, and fixes any failures.
Followup from #6090, this enables typechecking and linting in kv-asset-handler, and fixes any failures.
Followup from #6090, this enables typechecking and linting in kv-asset-handler, and fixes any failures.
Followup from #6090, this enables typechecking and linting in kv-asset-handler, and fixes any failures.
Some of our packages didn't have a lint/typecheck rule setup, so I added it. Also fixed a couple of failures along the way. I didn't enable linting for kv-asset-handler because that looks like a bit more work, which we can do later.
No changeset / tests for this, no functional changes.