eslint-config-zweitag

ESLint configuration for Zweitag projects

Usage no npm install needed!

<script type="module">
  import eslintConfigZweitag from 'https://cdn.skypack.dev/eslint-config-zweitag';
</script>

README

Zweitag JavaScript Guidelines

Usage

Create a .eslintrc.js file and add the following lines:

module.exports = {
  extends: 'zweitag',
  settings: {
    react: {
      version: '16.0' // React Version your app uses
    }
  }
}

If you are using an alias like '@' for the root directory, you need to install the additional eslint-import-resolver-alias. Modify the settings like that:

const path = require('path');

module.exports = {
  extends: 'zweitag',
  settings: {
    react: {
      version: '16.0' // React Version your app uses
    }
    'import/resolver': {
      alias: [
        ['@', path.resolve(process.cwd(), 'frontend/src')]
      ]
    }
  }
}

Resources

Learning ES6+

Read This

Tools

Other Style Guides

Other Styles

Further Reading

Books

Blogs

Podcasts

↑ back to top