eslint-config-airbnb Questions

1

Solved

I've applied eslint airbnb standard to my code, so now this code: handleSubmit = (event) => { event.preventDefault(); this.props.onSearch(this.query.value); event.target.blur(); } causes t...
Nonalcoholic asked 17/11, 2018 at 15:53

1

Hi I'm trying to find an eslint rule for empty lines before closing bracket: I'm using react, here there is the example: const test = () => ( <div> Hello </div> // This should sh...
Precise asked 15/10, 2018 at 22:38

1

Solved

I'm fighting with a minor issue with my eslint, it seems to work fine most of the time, but there are some cases that it doesn't work weel with React code. Let take as example this code: const ce...
Soupandfish asked 20/8, 2018 at 9:14

3

I am new in react. My app was running properly, but after adding eslint(airbnb), my apps failed to compile. export default class HelloWorldComponent extends React.Component { render() { return ...
Doughty asked 12/9, 2017 at 19:55

3

Solved

I have a stateless React component that looks like this: const propTypes = exact({ fieldId: PropTypes.string.isRequired, text: PropTypes.string.isRequired, }); function Label({ fieldId, text })...
Romanesque asked 20/11, 2017 at 22:32

1

Solved

Eslint(airbnb config) wants to have my params on new lines when I have multiple params. But when I do that, vscode formatting keeps giving 4 spaces indentation instead of 2 as expected. Result: c...
Vaccaro asked 7/2, 2018 at 22:18

1

Solved

I am using eslint with VSCode 1.18.1 and the prettier/prettier extension 0.26.0 for VSCode. In my VSCode config I have "prettier.eslintIntegration": true,. My dependencies used to be: "eslint": "^...

2

Solved

I'm using airbnb configuration for eslint and it's giving me this warning: [eslint] 'isLoading' is missing in props validation (react/prop-types) Is there a way to set PropTypes for isLoading? c...

1

Solved

I have a node 8 project in ES6, that also contains some client-side code in ES5. I'm linting the node code with eslint and using airbnb-base for it. However, the client-side code is ES5, so I want...
Cyte asked 5/11, 2017 at 13:8

2

Solved

I'm working in a project with several javascript files and part of what I'm doing right now is both migrating existing code to use newer ES6+ features as well as making sure we're abiding by the Ai...

2

Solved

I have global types defined in /flow-typed/redux.flow.js : declare type Action = {| +type: string, +payload: any, |} declare type State = {| +ui: UI, +user: User, +team: Team, +projects: Pr...
Myers asked 13/7, 2017 at 19:8

1

I'm on a ReactNative project and prefer to use airbnb. I have npm install airbnb global: npm install -g airbnb (and also dependencies) Made .eslintrc file with config "extends": eslint-config-air...
Erigeron asked 6/5, 2017 at 3:4

2

Solved

I need to exclude css files from the eslint parser. Currently when I run eslint src/** this is checking all the files including css files. . Please find below my eslintrc file contents. module.ex...
Atmolysis asked 26/4, 2017 at 6:9

1

Solved

I am trying to set up linting with Airbnb's Javascript standards on my React project, it uses webpack. Updated with latest packages based on comments. "babel-eslint": "^6.1.2", ...
Anthracene asked 4/8, 2016 at 3:10

© 2022 - 2024 — McMap. All rights reserved.