2.0.4 • Published 2 years ago

eslint-plugin-cup v2.0.4

Weekly downloads
3,945
License
MIT
Repository
github
Last release
2 years ago

eslint-plugin-cup

ESLint rules for create-universal-package

Rules

cup/no-undef

The same as the vanilla no-undef, but only allows environment-specific globals if guarded by environment checks.

process.title; // fails `cup/no-undef`
window.location; // fails `cup/no-undef`

// passes lint
if (__BROWSER__) {
  document.body.appendChild(document.createTextNode('hello world'));
}

// passes lint
if (__NODE__) {
  process.stdout.write('hello world');
}

// passes lint
const topLevel = __BROWSER__ ? window : global;
2.0.4

2 years ago

2.0.3

4 years ago

2.0.2

5 years ago

2.0.1

5 years ago

2.0.0

6 years ago

1.0.2

6 years ago

1.0.0

7 years ago

1.0.0-rc.5

7 years ago

1.0.0-rc.4

7 years ago

1.0.0-rc.3

7 years ago

1.0.0-rc.2

7 years ago

1.0.0-y.0

7 years ago