Socket
Socket
Sign inDemoInstall

@datawrapper/eslint-config

Package Overview
Dependencies
245
Maintainers
16
Versions
6
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    @datawrapper/eslint-config

Shared eslint-config for Datawrapper projects


Version published
Maintainers
16
Created

Readme

Source

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"
    ]
},

FAQs

Last updated on 31 May 2021

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc