0.2.2 • Published 3 years ago

@datawrapper/eslint-config v0.2.2

Weekly downloads
-
License
ISC
Repository
-
Last release
3 years ago

A shared set of eslint rules to be used across Datawrapper projects.

To use this config, install it via NPM:

npm install -D @datawrapper/eslint-config

Then you can include it in your project's eslint configuration, which most probably lives in its package.json:

"eslintConfig": {
    "extends": "@datawrapper/eslint-config"
}

For chart embeds, there is a particular restrictive set of rules that limits the use of certain window and document attributes:

"eslintConfig": {
    "extends": "@datawrapper/eslint-config/chart-plugin"
}

This config does not include the necessary parser and plugins for use with Svelte. Here's how the eslint-config for a chart plugin would look in practice:

"eslintConfig": {
    "parser": "babel-eslint",
    "extends": [
        "@datawrapper/eslint-config/chart-plugin",
        "plugin:@tivac/svelte/svelte"
    ],
    "plugins": [
        "html",
        "@tivac/svelte"
    ]
},
0.2.2

3 years ago

0.2.1

3 years ago

0.2.0

3 years ago

0.1.1

3 years ago

0.1.0

3 years ago

0.0.1

3 years ago