{"id":28912515,"url":"https://github.com/oceanprotocol/eslint-config-oceanprotocol","last_synced_at":"2025-10-03T14:12:28.257Z","repository":{"id":32653007,"uuid":"138896898","full_name":"oceanprotocol/eslint-config-oceanprotocol","owner":"oceanprotocol","description":"💅 🦋 ESLint config for keeping JavaScript consistent across all of Ocean Protocol's projects","archived":false,"fork":false,"pushed_at":"2023-03-01T05:01:04.000Z","size":404,"stargazers_count":9,"open_issues_count":6,"forks_count":3,"subscribers_count":13,"default_branch":"main","last_synced_at":"2025-09-29T23:22:56.835Z","etag":null,"topics":["butterflies","eslint","fabulous","linting","standard-js","style"],"latest_commit_sha":null,"homepage":"https://oceanprotocol.com","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/oceanprotocol.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2018-06-27T15:00:10.000Z","updated_at":"2022-11-02T22:28:18.000Z","dependencies_parsed_at":"2024-06-18T18:35:38.357Z","dependency_job_id":"0b48a880-721a-4fa7-9a74-c39a30897c48","html_url":"https://github.com/oceanprotocol/eslint-config-oceanprotocol","commit_stats":{"total_commits":78,"total_committers":7,"mean_commits":"11.142857142857142","dds":0.3076923076923077,"last_synced_commit":"eb31c2c957560df83ed75b2612c0b39d89e2346b"},"previous_names":[],"tags_count":19,"template":false,"template_full_name":null,"purl":"pkg:github/oceanprotocol/eslint-config-oceanprotocol","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/oceanprotocol%2Feslint-config-oceanprotocol","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/oceanprotocol%2Feslint-config-oceanprotocol/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/oceanprotocol%2Feslint-config-oceanprotocol/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/oceanprotocol%2Feslint-config-oceanprotocol/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/oceanprotocol","download_url":"https://codeload.github.com/oceanprotocol/eslint-config-oceanprotocol/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/oceanprotocol%2Feslint-config-oceanprotocol/sbom","scorecard":{"id":701391,"data":{"date":"2025-08-11","repo":{"name":"github.com/oceanprotocol/eslint-config-oceanprotocol","commit":"eb31c2c957560df83ed75b2612c0b39d89e2346b"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":3.7,"checks":[{"name":"Dangerous-Workflow","score":10,"reason":"no dangerous workflow patterns detected","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#dangerous-workflow"}},{"name":"Binary-Artifacts","score":10,"reason":"no binaries found in the repo","details":null,"documentation":{"short":"Determines if the project has generated executable (binary) artifacts in the source repository.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#binary-artifacts"}},{"name":"Maintained","score":0,"reason":"0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#maintained"}},{"name":"Code-Review","score":0,"reason":"Found 0/14 approved changesets -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project requires human code review before pull requests (aka merge requests) are merged.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#code-review"}},{"name":"Token-Permissions","score":0,"reason":"detected GitHub workflow tokens with excessive permissions","details":["Warn: no topLevel permission defined: .github/workflows/ci.yml:1","Warn: no topLevel permission defined: .github/workflows/publish.yml:1","Info: no jobLevel write permissions found"],"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#token-permissions"}},{"name":"Packaging","score":-1,"reason":"packaging workflow not detected","details":["Warn: no GitHub/GitLab publishing workflow detected."],"documentation":{"short":"Determines if the project is published as a package that others can easily download, install, easily update, and uninstall.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#packaging"}},{"name":"Pinned-Dependencies","score":3,"reason":"dependency not pinned by hash detected -- score normalized to 3","details":["Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/ci.yml:24: update your workflow using https://app.stepsecurity.io/secureworkflow/oceanprotocol/eslint-config-oceanprotocol/ci.yml/main?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/ci.yml:25: update your workflow using https://app.stepsecurity.io/secureworkflow/oceanprotocol/eslint-config-oceanprotocol/ci.yml/main?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/publish.yml:14: update your workflow using https://app.stepsecurity.io/secureworkflow/oceanprotocol/eslint-config-oceanprotocol/publish.yml/main?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/publish.yml:15: update your workflow using https://app.stepsecurity.io/secureworkflow/oceanprotocol/eslint-config-oceanprotocol/publish.yml/main?enable=pin","Info:   0 out of   4 GitHub-owned GitHubAction dependencies pinned","Info:   2 out of   2 npmCommand dependencies pinned"],"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#pinned-dependencies"}},{"name":"CII-Best-Practices","score":0,"reason":"no effort to earn an OpenSSF best practices badge detected","details":null,"documentation":{"short":"Determines if the project has an OpenSSF (formerly CII) Best Practices Badge.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#cii-best-practices"}},{"name":"Fuzzing","score":0,"reason":"project is not fuzzed","details":["Warn: no fuzzer integrations found"],"documentation":{"short":"Determines if the project uses fuzzing.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#fuzzing"}},{"name":"License","score":10,"reason":"license file detected","details":["Info: project has a license file: LICENSE:0","Info: FSF or OSI recognized license: Apache License 2.0: LICENSE:0"],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#license"}},{"name":"Signed-Releases","score":-1,"reason":"no releases found","details":null,"documentation":{"short":"Determines if the project cryptographically signs release artifacts.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#signed-releases"}},{"name":"Branch-Protection","score":-1,"reason":"internal error: error during branchesHandler.setup: internal error: githubv4.Query: Resource not accessible by integration","details":null,"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#branch-protection"}},{"name":"Security-Policy","score":10,"reason":"security policy file detected","details":["Info: security policy file detected: github.com/oceanprotocol/.github/SECURITY.md:1","Info: Found linked content: github.com/oceanprotocol/.github/SECURITY.md:1","Info: Found disclosure, vulnerability, and/or timelines in security policy: github.com/oceanprotocol/.github/SECURITY.md:1","Info: Found text in security policy: github.com/oceanprotocol/.github/SECURITY.md:1"],"documentation":{"short":"Determines if the project has published a security policy.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#security-policy"}},{"name":"SAST","score":0,"reason":"SAST tool is not run on all commits -- score normalized to 0","details":["Warn: 0 commits out of 17 are checked with a SAST tool"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#sast"}},{"name":"Vulnerabilities","score":0,"reason":"24 existing vulnerabilities detected","details":["Warn: Project is vulnerable to: GHSA-h5c3-5r3r-rr8q","Warn: Project is vulnerable to: GHSA-rmvr-2pp2-xj38","Warn: Project is vulnerable to: GHSA-xx4v-prfh-6cgc","Warn: Project is vulnerable to: GHSA-v6h2-p8h4-qcjw","Warn: Project is vulnerable to: GHSA-grv7-fg5c-xmjg","Warn: Project is vulnerable to: GHSA-3xgq-45jj-v275","Warn: Project is vulnerable to: GHSA-fjxv-7rqg-78g4","Warn: Project is vulnerable to: GHSA-rc47-6667-2j5j","Warn: Project is vulnerable to: GHSA-78xj-cgh5-2h22","Warn: Project is vulnerable to: GHSA-2p57-rm9w-gvfp","Warn: Project is vulnerable to: GHSA-9c47-m6qq-7p4h","Warn: Project is vulnerable to: GHSA-952p-6rrq-rcjv","Warn: Project is vulnerable to: GHSA-c2qf-rxjj-qqgw","Warn: Project is vulnerable to: GHSA-52f5-9888-hmc6","Warn: Project is vulnerable to: GHSA-4w2j-2rg4-5mjw","Warn: Project is vulnerable to: GHSA-mrgp-mrhc-5jrq","Warn: Project is vulnerable to: GHSA-7jxr-cg7f-gpgv","Warn: Project is vulnerable to: GHSA-xj72-wvfv-8985","Warn: Project is vulnerable to: GHSA-ch3r-j5x3-6q2m","Warn: Project is vulnerable to: GHSA-p5gc-c584-jj6v","Warn: Project is vulnerable to: GHSA-whpj-8f3w-67p5","Warn: Project is vulnerable to: GHSA-cchq-frgv-rjh5","Warn: Project is vulnerable to: GHSA-g644-9gfx-q4q4","Warn: Project is vulnerable to: GHSA-j8xg-fqg3-53r7"],"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}}]},"last_synced_at":"2025-08-22T05:17:34.116Z","repository_id":32653007,"created_at":"2025-08-22T05:17:34.116Z","updated_at":"2025-08-22T05:17:34.116Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":277919960,"owners_count":25899458,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-10-01T02:00:09.286Z","response_time":88,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["butterflies","eslint","fabulous","linting","standard-js","style"],"created_at":"2025-06-21T20:11:42.633Z","updated_at":"2025-10-03T14:12:28.252Z","avatar_url":"https://github.com/oceanprotocol.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"[![banner](https://raw.githubusercontent.com/oceanprotocol/art/master/github/repo-banner%402x.png)](https://oceanprotocol.com)\n\n\u003ch1 align=\"center\"\u003eeslint-config-oceanprotocol\u003c/h1\u003e\n\n\u003e 💅 🦋 Shareable ESLint config for keeping JavaScript consistent across all of Ocean Protocol's projects, built upon [JavaScript Standard Style](https://github.com/standard/standard).\n\n[![npm](https://img.shields.io/npm/v/eslint-config-oceanprotocol.svg)](https://www.npmjs.com/package/eslint-config-oceanprotocol)\n[![Build Status](https://github.com/oceanprotocol/eslint-config-oceanprotocol/workflows/CI/badge.svg)](https://github.com/oceanprotocol/eslint-config-oceanprotocol/actions)\n[![js oceanprotocol](https://img.shields.io/badge/js-oceanprotocol-7b1173.svg)](https://github.com/oceanprotocol/eslint-config-oceanprotocol)\n[![code style: prettier](https://img.shields.io/badge/code_style-prettier-7b1173.svg?style=flat-square)](https://github.com/prettier/prettier)\n\nThis cat clearly forgot to lint her JavaScript before deployment:\n\n![cat not linting correctly](https://raw.githubusercontent.com/bigchaindb/stylelint-config-bigchaindb/master/media/cat-linter-fail.gif)\u003cbr /\u003e\u003csub\u003eExhibit A: cat not linting correctly\u003c/sub\u003e\n\nDon't be like that cat.\n\n**Table of Contents**\n\n- [Usage](#usage)\n  - [React](#react)\n  - [Prettier](#prettier)\n  - [Editor Plugins](#editor-plugins)\n- [Rules](#rules)\n- [Development](#development)\n- [⬆️ Releases](#️-releases)\n  - [Production](#production)\n  - [Pre-Releases](#pre-releases)\n- [Changelog](#changelog)\n- [Contributing](#contributing)\n- [🏛 License](#-license)\n\n---\n\n## Usage\n\nFor every project containing JavaScript, ESLint should be set up with this base setup.\n\n```bash\nnpm install --save-dev eslint eslint-config-oceanprotocol\n```\n\nThen, create a new file `.eslintrc` in the root of your project and fill with:\n\n```json\n{\n  \"extends\": \"oceanprotocol\"\n}\n```\n\n### React\n\nWhen using within a React project use this to get set up:\n\n```bash\nnpm i -D eslint eslint-config-oceanprotocol\n```\n\nAnd in your `.eslintrc`:\n\n```json\n{\n  \"extends\": [\"oceanprotocol\", \"oceanprotocol/react\"]\n}\n```\n\n### Prettier\n\nAdditionally, you should add [Prettier](https://prettier.io) to your project and work with it through ESLint:\n\n```bash\nnpm i -D prettier eslint-config-prettier eslint-plugin-prettier\n```\n\nThen add a `.prettierrc` file to the root of your project with this content:\n\n```json\n{\n  \"semi\": false,\n  \"singleQuote\": true,\n  \"trailingComma\": \"none\"\n}\n```\n\nFinally, modify your `.eslintrc`:\n\n```json\n{\n  \"extends\": [\n    \"oceanprotocol\",\n    \"prettier/standard\",\n    \"plugin:prettier/recommended\"\n  ],\n  \"plugins\": [\"prettier\"]\n}\n```\n\n### Editor Plugins\n\nFor maximum fun during coding, install an ESLint plugin in your favorite editor to get suggestions and autofixes as you type.\n\n- VS Code: [ESLint](https://marketplace.visualstudio.com/items?itemName=dbaeumer.vscode-eslint)\n- Atom: [linter-eslint](https://atom.io/packages/linter-eslint)\n- PyCharm: [Installing, enabling, and configuring ESLint in PyCharm](https://www.jetbrains.com/help/pycharm/eslint.html)\n- Sublime Text: [SublimeLinter-eslint](https://github.com/SublimeLinter/SublimeLinter-eslint)\n- IntelliJ IDEA, RubyMine, WebStorm, PhpStorm, PyCharm, AppCode, Android Studio: [ESLint](https://plugins.jetbrains.com/plugin/7494-eslint)\n- Vim, NeoVim: [ALE](https://github.com/w0rp/ale)\n\n## Rules\n\nWe keep it simple and follow almost everything defined in the [JavaScript Standard Style](https://github.com/standard/standard). Only deviations are:\n\n- indentation: **2**\n- **no** space before function parenthesis\n- **double quotes** for jsx attributes\n- prefer destructuring from objects \u0026 arrays\n- enforce spacing inside curly braces\n\n## Development\n\nAgain, keeping it simple with 2 files for now:\n\n- `index.js`: holds all the custom JavaScript linting rules\n- `react.js`: holds all the custom React linting rules\n\nFor local development, clone this repo and install all dependencies:\n\n```bash\ngit clone git@github.com:oceanprotocol/eslint-config-oceanprotocol.git\ncd eslint-config-oceanprotocol/\n\nnpm i\n```\n\nLinting is setup against the actual rules within this repo so for testing new rules against every js file in this repo, you can run:\n\n```bash\nnpm test\n```\n\n## ⬆️ Releases\n\nReleases are managed semi-automatically. They are always manually triggered from a developer's machine with release scripts.\n\n### Production\n\nFrom a clean `main` branch you can run the release task bumping the version accordingly based on semantic versioning:\n\n```bash\nnpm run release\n```\n\nThe task does the following:\n\n- bumps the project version in `package.json`, `package-lock.json`\n- auto-generates and updates the CHANGELOG.md file from commit messages\n- creates a Git tag\n- commits and pushes everything\n- creates a GitHub release with commit messages as description\n- Git tag push will trigger a GitHub Action workflow to do a npm release\n\nFor the GitHub releases steps a GitHub personal access token, exported as `GITHUB_TOKEN` is required. [Setup](https://github.com/release-it/release-it#github-releases)\n\n### Pre-Releases\n\nFor pre-releases, this is required for the first one like `v0.18.0-next.0`:\n\n```bash\n./node_modules/.bin/release-it major|minor|patch --preRelease=next\n```\n\nFurther releases afterwards can be done with `npm run release` again and selecting the appropriate next version, in this case `v0.18.0-next.1` and so on.\n\n## Changelog\n\nSee the [CHANGELOG.md](./CHANGELOG.md) file. This file is auto-generated during the above mentioned release process.\n\n## Contributing\n\nSee the page titled \"[Ways to Contribute](https://docs.oceanprotocol.com/concepts/contributing/)\" in the Ocean Protocol documentation.\n\n## 🏛 License\n\n```\nCopyright ((C)) 2022 Ocean Protocol Foundation\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n   http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Foceanprotocol%2Feslint-config-oceanprotocol","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Foceanprotocol%2Feslint-config-oceanprotocol","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Foceanprotocol%2Feslint-config-oceanprotocol/lists"}