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

fix: comment eslint disable in cypress config #4910

Merged
merged 1 commit into from Jan 3, 2020

Commits on Dec 1, 2019

  1. fix: comment eslint disable in cypress config

    The current cypress config has a global eslint-disable:
    
    typescript
    ```
    /* eslint-disable import/no-extraneous-dependencies, global-require, arrow-body-style */
    // const webpack = require('@cypress/webpack-preprocessor')
    ```
    
    But this assumes that `eslint-import-plugin` is present, whereas this is only true when the selected preset is the Airbnb one.
    In other cases, this fails `yarn lint` right away with:
    
    ```
    error: Definition for rule 'import/no-extraneous-dependencies' was not found (import/no-extraneous-dependencies) at tests/e2e/plugins/index.js```
    
    Even if using the Airbnb preset, the comment does not have any effect, as, by default, the `require` call is commented.
    
    This commit now splits the rules disabling in two:
    
    - one commented for the people using Airbnb and who will uncomment the require call below, as it is only useful for them.
    - one activated that disables `arrow-body-style` as it will fail the linting for people using Airbnb preset with the current config.
    cexbrayat committed Dec 1, 2019
    Copy the full SHA
    fe376b2 View commit details
    Browse the repository at this point in the history