npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

@sap/eslint-plugin-webide-feature

v1.3.22

Published

Custom ESlint rules and recommended configuration specific for SAP Web IDE features

Downloads

18

Readme

ESLint plugin for SAP Web IDE features

Table of contents

Overview

This is the eslint plugin for Web IDE features. It contains a set of eslint rules and recommended ESLint configuration for static code checks to be used by Web IDE feature developers.

Usage

Add linting to tests

To add this package as a dependency in your package.json file, do the following:

  1. Under the "scripts" section, add: "lint": "eslint src"
  2. Under the "scripts" section, add: "npm run lint" to the test section: "test": "npm run lint && ..."
  3. Under the "devDependencies" section, add the following dependency: "@sap/eslint-plugin-webide-feature": "a.b.c"
  4. Add .eslintrc.json file with the following content:
{
	"plugins": ["@sap/webide-feature"],
	"extends": "plugin:@sap/webide-feature/recommended-internal"
}

The linting checks will be executed as part of tests.

Please note that each version of this ESLint plugin corresponds to certain version of SAP Web IDE. As cloud version of SAP Web IDE is continiously updated it is strongly recommended to update the version of this plugin as soon as it is released. To update your feature to use the latest version of ESLint plugin, run: npm install --save-exact @sap/eslint-plugin-webide-feature@latest

Fix existing lint issues

After you have added linting, please execute it with npm run lint. Do not worry if you see lots of warnings and errors most of the can be fixed automatically with --fix option of ESLint, by running node_modules/.bin/eslint src --fix. Remaining issues can be fixed manually or ignored by using special comments or overrding recommended configuration values. To fix the issues manually please refer to the documentation of specific rule.

List of rules

| Rule | Description | Recommended Severity | | :----------------------------------------------------------------------------- | :------------------------------------------------------------------------------------------------------ | :------------------- | | no-private-methods | Do not invoke private methods | Error | | no-private-apis | Do not invoke private methods | Warning | | bundled-uris-valid | "bundledPlugins" and "bundledFeatures" arrays items must start with "file:" and have valid uri | Error | | no-deprecated-fields | package.json file should contain neither deprecatedPluginExtensions nor deprecatedConfigIncludes fields | Warning | | feature-description-valid | package.json file must contain description field | Warning | | homepage-url-valid | package.json file must contain a homepage field with a valid path | Warning | | package-json-exists | package.json file must exist in feature's root folder | Error | | consistent-ids | each package.json and plugin.json file must has consistent ids | Error | | feature-name-valid | package.json file must contain name field | Error | | no-optional-features | package.json file must not contain optionalBundledFeatures field | Error | | feature-author-valid | package.json file must contain an author field with name and icon | Warning | | feature-version-valid | package.json file must contain a version field | Error | | webide-dependencies-consistent | "webideDependencies" section should be declared properly | Error | | plugin-name-valid | plugin.json file must contain name field | Error | | plugin-provides-valid | service and interface file references in "plugin.json" file must be valid | Error | | no-unused-required-services | All required services of a plugin must be in use | Warning | | valid-json-files | All JSON files in a feature must be valid | Error |