Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: antfu/eslint-config
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: v2.13.2
Choose a base ref
...
head repository: antfu/eslint-config
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: v2.13.3
Choose a head ref
  • 4 commits
  • 5 files changed
  • 1 contributor

Commits on Apr 10, 2024

  1. chore: update

    antfu committed Apr 10, 2024

    Verified

    This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
    Copy the full SHA
    2fe73a4 View commit details
  2. chore: update dev script

    antfu committed Apr 10, 2024
    Copy the full SHA
    2263538 View commit details
  3. Copy the full SHA
    2bc6f13 View commit details
  4. chore: release v2.13.3

    antfu committed Apr 10, 2024
    Copy the full SHA
    d7a157a View commit details
Showing with 81 additions and 157 deletions.
  1. +4 −40 eslint.config.js
  2. +36 −0 eslint.config.ts
  3. +5 −4 package.json
  4. +23 −105 pnpm-lock.yaml
  5. +13 −8 src/configs/test.ts
44 changes: 4 additions & 40 deletions eslint.config.js
Original file line number Diff line number Diff line change
@@ -1,42 +1,6 @@
// @ts-check
import styleMigrate from '@stylistic/eslint-plugin-migrate'
import JITI from 'jiti'
import { bundleRequire } from 'bundle-require'

const jiti = JITI(import.meta.url)
/**
* @type {import('./src').default}
*/
const antfu = jiti('./src').default

export default antfu(
{
vue: true,
react: true,
solid: true,
svelte: true,
astro: true,
typescript: true,
formatters: true,
},
{
ignores: [
'fixtures',
'_fixtures',
],
},
{
files: ['src/**/*.ts'],
rules: {
'perfectionist/sort-objects': 'error',
},
},
{
files: ['src/configs/*.ts'],
plugins: {
'style-migrate': styleMigrate,
},
rules: {
'style-migrate/migrate': ['error', { namespaceTo: 'style' }],
},
},
)
export default bundleRequire({
filepath: './eslint.config.ts',
}).then(r => r.mod.default)
36 changes: 36 additions & 0 deletions eslint.config.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
// @ts-expect-error missing types
import styleMigrate from '@stylistic/eslint-plugin-migrate'
import { antfu } from './src'

export default antfu(
{
vue: true,
react: true,
solid: true,
svelte: true,
astro: true,
typescript: true,
formatters: true,
},
{
ignores: [
'fixtures',
'_fixtures',
],
},
{
files: ['src/**/*.ts'],
rules: {
'perfectionist/sort-objects': 'error',
},
},
{
files: ['src/configs/*.ts'],
plugins: {
'style-migrate': styleMigrate,
},
rules: {
'style-migrate/migrate': ['error', { namespaceTo: 'style' }],
},
},
)
9 changes: 5 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@antfu/eslint-config",
"type": "module",
"version": "2.13.2",
"version": "2.13.3",
"packageManager": "pnpm@8.15.6",
"description": "Anthony's ESLint config",
"author": "Anthony Fu <anthonyfu117@hotmail.com> (https://github.com/antfu/)",
@@ -27,7 +27,7 @@
"scripts": {
"build": "nr typegen && tsup --format esm,cjs --clean --dts",
"stub": "tsup --format esm",
"dev": "tsup --format esm,cjs --watch & npx @eslint/config-inspector",
"dev": "npx @eslint/config-inspector --config eslint.config.ts",
"build:inspector": "pnpm build && npx @eslint/config-inspector build",
"watch": "tsup --format esm,cjs --watch",
"lint": "eslint .",
@@ -112,7 +112,7 @@
"eslint-plugin-toml": "^0.11.0",
"eslint-plugin-unicorn": "^52.0.0",
"eslint-plugin-unused-imports": "^3.1.0",
"eslint-plugin-vitest": "^0.5.0",
"eslint-plugin-vitest": "^0.5.1",
"eslint-plugin-vue": "^9.24.1",
"eslint-plugin-yml": "^1.14.0",
"eslint-processor-vue-blocks": "^0.1.1",
@@ -130,7 +130,7 @@
"@antfu/eslint-config": "workspace:*",
"@antfu/eslint-plugin-prettier": "^5.0.1-1",
"@antfu/ni": "^0.21.12",
"@eslint/config-inspector": "^0.4.4",
"@eslint/config-inspector": "^0.4.5",
"@stylistic/eslint-plugin-migrate": "^1.7.0",
"@types/eslint": "^8.56.7",
"@types/fs-extra": "^11.0.4",
@@ -140,6 +140,7 @@
"@unocss/eslint-plugin": "^0.59.0",
"astro-eslint-parser": "^0.17.0",
"bumpp": "^9.4.0",
"bundle-require": "^4.0.2",
"eslint": "^9.0.0",
"eslint-plugin-astro": "^0.34.0",
"eslint-plugin-format": "^0.1.0",
Loading