Skip to content
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

ESLint for Meteor 3 readiness #1

Open
5 of 11 tasks
filipenevola opened this issue Oct 24, 2023 · 1 comment
Open
5 of 11 tasks

ESLint for Meteor 3 readiness #1

filipenevola opened this issue Oct 24, 2023 · 1 comment
Assignees

Comments

@filipenevola
Copy link
Contributor

filipenevola commented Oct 24, 2023

We could create an eslint plugin for Meteor 3 readiness.

For example, today, in Meteor 2.13, you can create an async Method or a sync Method, but the latter is not going to work with Meteor 3 if you have any async call inside it, and you will probably have as Mongo calls are going to be all async.

The benefit of eslint plugins is that we can later add rules and turn them on and off for each project, file, or line.

So we don't need to migrate everything at once.

Pre Tasks

  • Integrate walker from zodern with ESLint
  • Improve walker to consider mainModule as well
  • Make sure we take into account Meteor.isServer and Meteor.isClient

Tasks

  • Check all old methods no longer available with ESLint rules and add these rules in Meteor eslint - List of changes
  • Detect direct use of Fiber, Future
  • Detect direct use of Promise.await or promise.await

Optional tasks

  • Run in local packages as well?
  • Make eslint to work with packages
  • Other use-cases not covered
    • callback-hook: forEach
    • Cursor: [Symbol.asyncIterator]
    • ddp-server: call and apply
@filipenevola
Copy link
Contributor Author

We've created a new plugin

It's still a working in progress but with it I was able to find 8 places in CodeFTW.dev that were missing migration 😮

@filipenevola filipenevola self-assigned this Dec 15, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: In Progress
Development

No branches or pull requests

3 participants