Skip to content

Commit 0ba031f

Browse files
committed
chore: remove (deprecated) eslint-config-google
1 parent a7c455f commit 0ba031f

34 files changed

+231
-178
lines changed

.eslintignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,3 +23,4 @@
2323
##
2424

2525
/dist
26+
/test/fixtures

.eslintrc

Lines changed: 26 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,42 @@
11
{
22
"extends": [
33
"eslint:recommended",
4-
"google"
4+
"airbnb-base"
55
],
66
"parserOptions": {
7-
"ecmaVersion": 2020
7+
"ecmaVersion": "latest"
88
},
99
"env": {
1010
"es6": true,
1111
"node": true
1212
},
1313
"rules": {
1414
"max-len": [2, 150, 2],
15+
16+
"import/prefer-default-export": "off",
17+
18+
"import/no-extraneous-dependencies": ["error", {
19+
"devDependencies": [
20+
"scripts/**/*.js",
21+
"test/**/*.js",
22+
"gulpfile.js"
23+
]
24+
}],
25+
26+
"operator-linebreak": "off",
27+
"consistent-return": "off",
28+
"no-underscore-dangle": "off",
29+
"no-plusplus": "off",
30+
"quote-props": ["error", "consistent-as-needed"],
31+
"no-use-before-define": ["error", {
32+
"functions": false,
33+
"classes": true,
34+
"variables": true,
35+
"allowNamedExports": true
36+
}],
37+
1538
"no-console": [0],
39+
1640
"valid-jsdoc": [2, {
1741
"requireReturn": true,
1842
"requireParamDescription": true,

package.json

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,9 +57,11 @@
5757
"@rollup/plugin-virtual": "3.0.2",
5858
"@typescript-eslint/eslint-plugin": "7.10.0",
5959
"@typescript-eslint/parser": "7.10.0",
60+
"ansi-colors": "4.1.3",
6061
"babel-plugin-add-module-exports": "1.0.4",
6162
"eslint": "8.57.0",
62-
"eslint-config-google": "0.14.0",
63+
"eslint-config-airbnb-base": "15.0.0",
64+
"eslint-plugin-import": "2.29.1",
6365
"fancy-log": "2.0.0",
6466
"fs-extra": "11.2.0",
6567
"globalthis": "1.0.4",

scripts/build/index.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,8 +29,8 @@ const rollupConfig = require('./rollup.config');
2929
const config = require('../config');
3030

3131
module.exports = gulp.series(
32-
buildOutput,
33-
copyTypings,
32+
buildOutput,
33+
copyTypings,
3434
);
3535

3636
// eslint-disable-next-line require-jsdoc

scripts/build/rollup.config.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,7 @@ const prettier = require('rollup-plugin-prettier');
3434

3535
const config = require('../config');
3636
const pkg = require('../../package.json');
37+
3738
const license = fs.readFileSync(path.join(config.root, 'LICENSE'), 'utf-8');
3839

3940
module.exports = {

scripts/changelog/index.js

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -28,8 +28,8 @@ const conventionalChangelog = require('gulp-conventional-changelog');
2828
const config = require('../config');
2929

3030
module.exports = function changelog() {
31-
const changelog = path.join(config.root, 'CHANGELOG.md');
32-
return gulp.src(changelog, {buffer: false})
33-
.pipe(conventionalChangelog({releaseCount: 0}))
34-
.pipe(gulp.dest(config.root));
31+
const changelogFile = path.join(config.root, 'CHANGELOG.md');
32+
return gulp.src(changelogFile, { buffer: false })
33+
.pipe(conventionalChangelog({ releaseCount: 0 }))
34+
.pipe(gulp.dest(config.root));
3535
};

scripts/clean/index.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
* SOFTWARE.
2323
*/
2424

25-
const {rimraf} = require('rimraf');
25+
const { rimraf } = require('rimraf');
2626
const config = require('../config');
2727

2828
module.exports = function clean() {

scripts/config.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,7 @@
2323
*/
2424

2525
const path = require('node:path');
26+
2627
const ROOT = path.join(__dirname, '..');
2728

2829
module.exports = {

scripts/lint/index.js

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,8 +52,12 @@ module.exports = function lint() {
5252
log.debug(` ${input}`)
5353
));
5454

55-
const {ESLint} = require('eslint');
55+
// eslint-disable-next-line global-require
56+
const { ESLint } = require('eslint');
57+
58+
// eslint-disable-next-line global-require
5659
const fancyLog = require('fancy-log');
60+
5761
const eslint = new ESLint({
5862
errorOnUnmatchedPattern: false,
5963
});

scripts/release/index.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ function bumpVersion(type) {
6464
*/
6565
function prepareNextRelease() {
6666
return run(`git rm -r "${config.dist}"`).then(() => (
67-
run(`git commit -m 'release: prepare next release'`)
67+
run("git commit -m 'release: prepare next release'")
6868
));
6969
}
7070

@@ -86,8 +86,8 @@ function createReleaseTask(level) {
8686
}
8787

8888
return gulp.series(
89-
doRelease,
90-
prepareNextRelease,
89+
doRelease,
90+
prepareNextRelease,
9191
);
9292
}
9393

0 commit comments

Comments
 (0)