Skip to content

Commit

Permalink
chore: update eslint
Browse files Browse the repository at this point in the history
  • Loading branch information
Akryum committed May 31, 2024
1 parent b928d3a commit 042c73e
Show file tree
Hide file tree
Showing 7 changed files with 585 additions and 448 deletions.
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@
"docs:serve": "cd packages/docs && vitepress serve src"
},
"devDependencies": {
"@antfu/eslint-config": "^2.6.4",
"@antfu/eslint-config": "^2.19.1",
"@tailwindcss/postcss7-compat": "^2.0.4",
"@types/chrome": "^0.0.139",
"@types/speakingurl": "^13.0.3",
Expand All @@ -56,7 +56,7 @@
"concurrently": "^5.1.0",
"cross-env": "^5.2.0",
"cypress": "^3.1.0",
"eslint": "^8.56.0",
"eslint": "^9.3.0",
"execa": "^4.0.3",
"inquirer": "^6.2.0",
"lerna": "^4.0.0",
Expand Down
1 change: 1 addition & 0 deletions packages/app-frontend/src/features/ui/components/icons.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ export default {
icons.keys().forEach((key, index) => {
let result = icons(key)
const [, iconName] = /(\w+)\/materialicons/.exec(key)
// eslint-disable-next-line regexp/no-super-linear-backtracking
const [, content] = /<svg.+?>(.*)<\/svg>/.exec(result)
result = `<svg xmlns="http://www.w3.org/2000/svg" id="ic_${iconName}_standard" viewBox="0 0 24 24">${content}</svg>`
sprites[spriteIndex] += result
Expand Down
2 changes: 1 addition & 1 deletion packages/app-frontend/src/plugins/i18n.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { simpleGet } from '@vue-devtools/shared-utils'
import type { Plugin } from 'vue'

const reg = /\{\{\s*([\w_.-]+)\s*\}\}/g
const reg = /\{\{\s*([\w.-]+)\s*\}\}/g

interface StringMap { [key: string]: string | StringMap }
interface ValuesMap { [key: string]: any }
Expand Down
4 changes: 2 additions & 2 deletions packages/app-frontend/src/util/format/value.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@ import {
specialTokenToString,
} from '@vue-devtools/shared-utils'

const rawTypeRE = /^\[object (\w+)]$/
const specialTypeRE = /^\[native (\w+) (.*?)(<>((.|\s)*))?\]$/
const rawTypeRE = /^\[object (\w+)\]$/
const specialTypeRE = /^\[native (\w+) (.*?)(?:<>[.\s]*)?\]$/

export function valueType(value, raw = true) {
const type = typeof value
Expand Down
4 changes: 2 additions & 2 deletions packages/shared-utils/src/util.ts
Original file line number Diff line number Diff line change
Expand Up @@ -400,7 +400,7 @@ export function basename(filename, ext) {
filename = filename.replace(`/index${ext}`, ext)
}
return path.basename(
filename.replace(/^[a-zA-Z]:/, ''),
filename.replace(/^[a-z]:/i, ''),
ext,
)
}
Expand Down Expand Up @@ -544,7 +544,7 @@ export function parse(data: any, revive = false) {
: parseCircularAutoChunks(data)
}

const specialTypeRE = /^\[native (\w+) (.*?)(<>((.|\s)*))?\]$/
const specialTypeRE = /^\[native (\w+) (.*?)(?:<>[.\s]*)?\]$/
const symbolRE = /^\[native Symbol Symbol\((.*)\)\]$/

function reviver(key, val) {
Expand Down
1 change: 0 additions & 1 deletion packages/shell-host/src/DevIframe.vue
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,6 @@ export default defineComponent({
let init = false
let loadListener
function onLoad() {
loading.value = false
if (init) {
Expand Down
Loading

0 comments on commit 042c73e

Please sign in to comment.