-
Notifications
You must be signed in to change notification settings - Fork 2.2k
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
Support @typescript-eslint/no-unused-vars rule #502
Conversation
✔️ Deploy Preview for cypress-example-kitchensink ready! 🔨 Explore the source changes: 7913c0a 🔍 Inspect the deploy log: https://app.netlify.com/sites/cypress-example-kitchensink/deploys/60f9e9d51497f80008c203e5 😎 Browse the preview: https://deploy-preview-502--cypress-example-kitchensink.netlify.app |
Test summaryRun details
View run in Cypress Dashboard ➡️ This comment has been generated by cypress-bot as a result of this project's GitHub integration settings. You can manage this integration in this project's settings in the Cypress Dashboard |
"This branch has conflicts that must be resolved". This PR changes a file which no longer exists under Cypress 10+ Did you approve it by accident? Can we check that the issue it was addressing still exists? |
// eslint-disable-next-line no-unused-vars
module.exports = (on, config) => {
// `on` is used to hook into various events Cypress emits
// `config` is the resolved Cypress config
} The file remains after updating to Cypress After a clean installation of Cypress |
The issue targeted by this PR is obsolete and the PR can be closed. There is nothing to fix anymore. Modifications to examples in this repo (cypress-io/cypress-example-kitchensink) only flow into future versions of Cypress. They do not affect released versions or existing installations. The issue only affects installations of Cypress Legacy configuration: Folders/files which were originally installed using Cypress 9 and lower. Installations using Cypress current Configuration: Folders/files which were originally installed using Cypress 10+ are not affected. There is no file |
This PR should be closed because it is obsolete, but also because it would not have worked even if it had been dealt with in a timely manner. Perhaps @karlhorky or one of the Cypress.io team could close it? RebasingAttempting to rebase the branch https://github.com/karlhorky/cypress-example-kitchensink/tree/patch-2 on the
Since there is no other change in the PR apart from a modification to the deleted file cypress/plugins/index.js, after resolving the conflict, there is nothing left in the PR. EffectivenessIt seems also that there was a misconception that changing glob('./cypress/integration/**/*.js', { realpath: true }, (err, specFiles) => {
if (err) throw err
htmlFiles.concat(specFiles).forEach(function (file) {
return replaceStringsIn(file)
})
}) So even if Cypress were still using the layout which is now legacy, the PR would not have had the desired effect. |
Yeah I'm thinking also that this PR is no longer needed. If I see this happening in the latest versions, I'll open a new PR. |
Thanks for closing! I'm going through some of the eslint aspects at the moment, so please flag any issues if you find any new ones. |
User facing changelog
This disables the ESLint
@typescript-eslint/no-unused-vars
rule (the typed counterpart to ESLint's built-inno-unused-vars
)Additional details
The files scaffolded by Cypress create an error out of the box for those users who are using
@typescript-eslint/no-unused-vars
instead ofno-unused-vars
This rule is also possible (and desirable) to use with JS files as well - it offers additional type information even in JS files so that the rule catches more problems.
How has the user experience changed?
Before: Error out of the box
After: No error
Original PR: cypress-io/cypress#17432
cc @flotwig