Skip to content

Commit

Permalink
Merge pull request #20 from toyokumo/develop
Browse files Browse the repository at this point in the history
release v2.1
  • Loading branch information
syunta authored Aug 5, 2024
2 parents 93cc197 + a0302ca commit dbeeb76
Show file tree
Hide file tree
Showing 8 changed files with 45 additions and 28 deletions.
11 changes: 10 additions & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,10 +22,19 @@ jobs:
node-version: "20.x"
cache: pnpm
cache-dependency-path: 'package.json'
registry-url: https://registry.npmjs.org

- run: pnpm publish
- run: pnpm publish --registry=https://registry.npmjs.org
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}

- uses: actions/setup-node@v4
with:
node-version: "20.x"
cache: pnpm
cache-dependency-path: 'package.json'
registry-url: https://npm.pkg.github.com

- run: pnpm publish --registry=https://npm.pkg.github.com
env:
NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@

All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.

## [2.1.0](https://github.com/toyokumo/eslint-config/compare/v2.0.14...v2.1.0) (2024-08-05)

### [2.0.14](https://github.com/toyokumo/eslint-config/compare/v2.0.13...v2.0.14) (2024-08-02)

### [2.0.13](https://github.com/toyokumo/eslint-config/compare/v2.0.12...v2.0.13) (2024-05-15)
Expand Down
41 changes: 21 additions & 20 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@toyokumo/eslint-config",
"version": "2.0.14",
"version": "2.1.0",
"engines": {
"node": ">=18"
},
Expand All @@ -9,7 +9,7 @@
"scripts": {
"test": "node --experimental-vm-modules node_modules/jest/bin/jest.js",
"lint": "eslint --max-warnings=0 \"**/*.{js,ts,tsx}\"",
"release": "standard-version",
"release": "standard-version --release-as minor",
"format": "run-s \"format:eslint -- {1}\" \"format:prettier -- {1}\" --",
"format:eslint": "eslint --fix",
"format:prettier": "prettier --write",
Expand Down Expand Up @@ -38,34 +38,35 @@
"rules"
],
"dependencies": {
"@eslint/eslintrc": "^3.0.2",
"@eslint/js": "^9.0.0",
"@next/eslint-plugin-next": "^14.1.4",
"@typescript-eslint/parser": "^7.6.0",
"@eslint/compat": "^1.1.1",
"@eslint/eslintrc": "^3.1.0",
"@eslint/js": "^9.8.0",
"@next/eslint-plugin-next": "^14.2.5",
"@typescript-eslint/parser": "^8.0.0",
"eslint-config-prettier": "^9.1.0",
"eslint-import-resolver-typescript": "^3.6.1",
"eslint-plugin-import": "^2.29.1",
"eslint-plugin-jest": "^27.4.0",
"eslint-plugin-jsx-a11y": "^6.8.0",
"eslint-plugin-react": "^7.34.1",
"eslint-plugin-react-hooks": "^4.6.0",
"eslint-plugin-tailwindcss": "^3.15.1",
"globals": "^15.0.0",
"tailwindcss": "^3.4.3",
"typescript-eslint": "^7.7.0"
"eslint-plugin-jest": "^28.7.0",
"eslint-plugin-jsx-a11y": "^6.9.0",
"eslint-plugin-react": "^7.35.0",
"eslint-plugin-react-hooks": "^4.6.2",
"eslint-plugin-tailwindcss": "^3.17.4",
"globals": "^15.9.0",
"tailwindcss": "^3.4.7",
"typescript-eslint": "^8.0.0"
},
"devDependencies": {
"@toyokumo/prettier-config": "^1.1.1",
"@types/eslint": "^8.56.7",
"eslint": "^8.57.0",
"@toyokumo/prettier-config": "^1.1.2",
"@types/eslint": "^9.6.0",
"eslint": "^9.8.0",
"jest": "^29.7.0",
"npm-run-all": "^4.1.5",
"prettier": "^3.2.5",
"prettier": "^3.3.3",
"standard-version": "^9.5.0",
"typescript": "^5.4.4"
"typescript": "^5.5.4"
},
"peerDependencies": {
"@toyokumo/prettier-config": ">=1.1",
"eslint": "^8.21.0"
"eslint": "^9.8"
}
}
3 changes: 2 additions & 1 deletion rules/javascript.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
const config = require('./config-helper.js');
const importPlugin = require('eslint-plugin-import');
const importRule = require('./import.js');
const { fixupPluginRules } = require('@eslint/compat');

module.exports = config({
files: ['**/*.js', '**/*.cjs', '**/*.mjs'],
Expand All @@ -15,7 +16,7 @@ module.exports = config({
},
},
plugins: {
import: importPlugin,
import: fixupPluginRules(importPlugin),
},
settings: {
// This will do the trick (https://github.com/import-js/eslint-plugin-import/issues/2556)
Expand Down
3 changes: 2 additions & 1 deletion rules/next.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
const nextPlugin = require('@next/eslint-plugin-next');
const { fixupPluginRules } = require('@eslint/compat');

/*
this rule depends on rules of typescript and tsx, react.
Expand Down Expand Up @@ -30,7 +31,7 @@ module.exports = [
{
files: ['**/*.ts', '**/*.tsx'],
plugins: {
'@next/next': nextPlugin,
'@next/next': fixupPluginRules(nextPlugin),
},
rules: {
...nextPlugin.configs.recommended.rules,
Expand Down
7 changes: 4 additions & 3 deletions rules/react.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ const reactPlugin = require('eslint-plugin-react');
const reactRecommended = require('eslint-plugin-react/configs/recommended.js');
const hooksPlugin = require('eslint-plugin-react-hooks');
const jsxA11yPlugin = require('eslint-plugin-jsx-a11y');
const { fixupPluginRules } = require('@eslint/compat');

/*
this rule depends on rules of typescript and tsx.
Expand Down Expand Up @@ -32,9 +33,9 @@ module.exports = [
{
files: ['**/*.ts', '**/*.tsx'],
plugins: {
react: reactPlugin,
'react-hooks': hooksPlugin,
'jsx-a11y': jsxA11yPlugin,
react: fixupPluginRules(reactPlugin),
'react-hooks': fixupPluginRules(hooksPlugin),
'jsx-a11y': fixupPluginRules(jsxA11yPlugin),
},
settings: {
...reactRecommended.languageOptions,
Expand Down
3 changes: 2 additions & 1 deletion rules/tailwindcss.js
Original file line number Diff line number Diff line change
@@ -1,11 +1,12 @@
const config = require('./config-helper.js');
const { FlatCompat } = require('@eslint/eslintrc');
const { fixupPluginRules } = require('@eslint/compat');

const compat = new FlatCompat();

module.exports = config({
files: ['**/*.ts', '**/*.tsx'],
extends: [...compat.extends('plugin:tailwindcss/recommended')],
extends: [...fixupPluginRules(compat.extends('plugin:tailwindcss/recommended'))],
rules: {
'tailwindcss/migration-from-tailwind-2': 'off',
},
Expand Down
3 changes: 2 additions & 1 deletion rules/typescript.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ const importRule = require('./import.js');
const tsEslint = require('typescript-eslint');
const tsParser = require('@typescript-eslint/parser');
const globals = require('globals');
const { fixupPluginRules } = require('@eslint/compat');

module.exports = config({
files: ['**/*.ts', '**/*.tsx'],
Expand All @@ -24,7 +25,7 @@ module.exports = config({
},
},
plugins: {
import: importPlugin,
import: fixupPluginRules(importPlugin),
},
settings: {
// https://github.com/import-js/eslint-import-resolver-typescript#configuration
Expand Down

0 comments on commit dbeeb76

Please sign in to comment.