Skip to content

Commit 3ed6f24

Browse files
committed
feat(@pixiv/eslint-config): init
0 parents  commit 3ed6f24

30 files changed

+6457
-0
lines changed

.changeset/README.md

+8
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
# Changesets
2+
3+
Hello and welcome! This folder has been automatically generated by `@changesets/cli`, a build tool that works
4+
with multi-package repos, or single-package repos to help you version and publish your code. You can
5+
find the full documentation for it [in our repository](https://github.com/changesets/changesets)
6+
7+
We have a quick list of common questions to get you started engaging with this project in
8+
[our documentation](https://github.com/changesets/changesets/blob/main/docs/common-questions.md)

.changeset/config.json

+11
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
{
2+
"$schema": "https://unpkg.com/@changesets/[email protected]/schema.json",
3+
"changelog": "@changesets/cli/changelog",
4+
"commit": false,
5+
"fixed": [],
6+
"linked": [],
7+
"access": "restricted",
8+
"baseBranch": "main",
9+
"updateInternalDependencies": "patch",
10+
"ignore": []
11+
}

.changeset/metal-trains-dress.md

+5
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"@pixiv/eslint-config": patch
3+
---
4+
5+
feat: use @next/eslint-plugin-next directly

.changeset/moody-bananas-argue.md

+7
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
---
2+
"@pixiv/eslint-config": patch
3+
---
4+
5+
BREAKING: update eslint-config-react-hooks to v5 https://github.com/facebook/react/releases/tag/eslint-plugin-react-hooks%405.0.0
6+
7+
chore: update deps

.changeset/odd-flowers-design.md

+5
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"@pixiv/eslint-config": patch
3+
---
4+
5+
chore: bump deps

.changeset/pre.json

+15
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
{
2+
"mode": "pre",
3+
"tag": "experimental",
4+
"initialVersions": {
5+
"@pixiv/eslint-config": "0.0.0-experimental-0"
6+
},
7+
"changesets": [
8+
"metal-trains-dress",
9+
"moody-bananas-argue",
10+
"odd-flowers-design",
11+
"short-pugs-return",
12+
"sixty-toys-learn",
13+
"weak-papayas-call"
14+
]
15+
}

.changeset/short-pugs-return.md

+5
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"@pixiv/eslint-config": patch
3+
---
4+
5+
lazy init config options

.changeset/sixty-toys-learn.md

+5
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"@pixiv/eslint-config": patch
3+
---
4+
5+
chore: bump deps

.changeset/weak-papayas-call.md

+5
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"@pixiv/eslint-config": patch
3+
---
4+
5+
feat: init release

.github/workflows/publish.yml

+31
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
name: Publish Package to npmjs
2+
3+
on:
4+
release:
5+
types: [created]
6+
workflow_dispatch:
7+
jobs:
8+
build:
9+
runs-on: ubuntu-latest
10+
permissions:
11+
contents: read
12+
id-token: write
13+
steps:
14+
- uses: actions/checkout@v4
15+
- uses: pnpm/action-setup@v4
16+
name: Install pnpm
17+
with:
18+
version: 9
19+
- uses: actions/setup-node@v4
20+
with:
21+
cache: pnpm
22+
node-version: '20.x'
23+
registry-url: 'https://registry.npmjs.org'
24+
- name: publish
25+
run: |
26+
pnpm install
27+
pnpm -r build
28+
pnpm -r publish --access public --no-git-checks
29+
env:
30+
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
31+
NPM_CONFIG_PROVENANCE: true

.github/workflows/test.yml

+27
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
name: Test
2+
3+
on: push
4+
5+
defaults:
6+
run:
7+
shell: bash
8+
9+
jobs:
10+
test-and-build:
11+
runs-on: ubuntu-latest
12+
steps:
13+
- uses: actions/checkout@v4
14+
- uses: pnpm/action-setup@v4
15+
name: Install pnpm
16+
with:
17+
version: 9
18+
- uses: actions/setup-node@v4
19+
with:
20+
cache: pnpm
21+
node-version: '20.x'
22+
registry-url: 'https://registry.npmjs.org'
23+
- name: build
24+
run: |
25+
pnpm install
26+
pnpm vitest run
27+
pnpm -r build

.gitignore

+5
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
node_modules
2+
tmp
3+
dist
4+
5+
.npmrc

.node-version

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
lts

README.md

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
# frontend-config

package.json

+23
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
{
2+
"name": "config",
3+
"version": "1.0.0",
4+
"description": "",
5+
"main": "index.js",
6+
"type": "module",
7+
"private": true,
8+
"keywords": [],
9+
"engines": {
10+
"pnpm": ">= 9"
11+
},
12+
"devDependencies": {
13+
"eslint": "9.11.1",
14+
"@babel/preset-typescript": "7.25.7",
15+
"@changesets/cli": "2.27.9",
16+
"@types/node": "22.7.4",
17+
"typescript": "5.6.2",
18+
"vitest": "2.1.2"
19+
},
20+
"resolutions": {
21+
"eslint": "9.11.1"
22+
}
23+
}

packages/eslint-config/.npmignore

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
__snapshots__

packages/eslint-config/CHANGELOG.md

+38
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
# @pixiv/eslint-config
2+
3+
## 0.0.0-experimental.5
4+
5+
### Patch Changes
6+
7+
- BREAKING: update eslint-config-react-hooks to v5, see https://github.com/facebook/react/releases/tag/eslint-plugin-react-hooks%405.0.0
8+
- chore: update deps
9+
10+
## 0.0.0-experimental.4
11+
12+
### Patch Changes
13+
14+
- chore: bump deps
15+
16+
## 0.0.0-experimental.3
17+
18+
### Patch Changes
19+
20+
- feat: use @next/eslint-plugin-next directly
21+
22+
## 0.0.0-experimental.2
23+
24+
### Patch Changes
25+
26+
- chore: bump deps
27+
28+
## 0.0.0-experimental.1
29+
30+
### Patch Changes
31+
32+
- fix: lazy init config options
33+
34+
## 0.0.0-experimental.0
35+
36+
### Patch Changes
37+
38+
- feat: init release

packages/eslint-config/README.md

+47
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
# @pixiv/eslint-config
2+
3+
`pnpm add eslint @pixiv/eslint-config`
4+
5+
eslint.config.mjs
6+
7+
```js
8+
import pixiv from '@pixiv/eslint-config';
9+
10+
export default pixiv.configs.recommended;
11+
```
12+
13+
また
14+
15+
```js
16+
import pixiv from '@pixiv/eslint-config';
17+
18+
export default [
19+
{
20+
ignores: ['tmp', 'vendor', 'public/packs'],
21+
},
22+
...pixiv.configs.recommended,
23+
{
24+
rules: {
25+
'react/self-closing-comp': 'warn',
26+
'import/first': 'warn',
27+
'object-shorthand': 'warn',
28+
curly: 'off',
29+
},
30+
},
31+
];
32+
```
33+
34+
## Goals and non-goals
35+
36+
### Goals
37+
38+
- Reduce the cost for managing eslint related dependencies
39+
40+
### Non-goals
41+
42+
- Managing extremely opinionated lint rules
43+
44+
## Known issues
45+
46+
- This package contains many deps that might not be used
47+
- In some condition it's required to set `public-hoist-pattern[]=eslint-*` in .npmrc

packages/eslint-config/package.json

+55
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,55 @@
1+
{
2+
"name": "@pixiv/eslint-config",
3+
"version": "0.0.0-experimental.5",
4+
"description": "pixiv's base eslint config",
5+
"author": "pixiv",
6+
"publishConfig": {
7+
"provenance": true
8+
},
9+
"type": "module",
10+
"main": "dist/index.js",
11+
"types": "dist/index.d.ts",
12+
"scripts": {
13+
"build": "tsup src/index.ts --clean --dts --format esm",
14+
"prepublish": "pnpm build"
15+
},
16+
"exports": {
17+
".": {
18+
"default": "./dist/index.js"
19+
}
20+
},
21+
"repository": {
22+
"type": "git",
23+
"url": "https://github.com/pixiv/frontend-config.git",
24+
"directory": "packages/eslint-config"
25+
},
26+
"files": [
27+
"README.md",
28+
"CHANGELOG.md",
29+
"src",
30+
"dist"
31+
],
32+
"peerDependencies": {
33+
"eslint": "^9.0.0"
34+
},
35+
"dependencies": {
36+
"@eslint/compat": "1.2.0",
37+
"@eslint/eslintrc": "3.1.0",
38+
"@eslint/js": "9.12.0",
39+
"@next/eslint-plugin-next": "14.2.14",
40+
"@typescript-eslint/eslint-plugin": "8.8.1",
41+
"@typescript-eslint/parser": "8.8.1",
42+
"eslint-config-prettier": "9.1.0",
43+
"eslint-plugin-import": "2.31.0",
44+
"eslint-plugin-jsx-a11y": "6.10.0",
45+
"eslint-plugin-react": "7.37.1",
46+
"eslint-plugin-react-compiler": "0.0.0-experimental-fa06e2c-20241014",
47+
"eslint-plugin-react-hooks": "5.0.0",
48+
"eslint-plugin-storybook": "0.9.0",
49+
"globals": "15.10.0",
50+
"typescript-eslint": "8.8.1"
51+
},
52+
"devDependencies": {
53+
"tsup": "8.3.0"
54+
}
55+
}

packages/eslint-config/pnpm-lock.yaml

+9
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)