Files
NapCatQQ/.pnpm-store/v3/files/83/b3c8bf5a7722baca47082b0d73c463cc349d87733d874450d60d9362daba22d65e008fa6080074032e9e9304dea3527a3465bb7eacec020cd2baa1d1dbb801
T
TanTan e311ca3275
Build NapCat Artifacts / Type Check & Test (push) Waiting to run
docs: 仓库链接指向本镜像仓库
2026-11-13 09:25:58 +08:00

41 lines
1.2 KiB
Plaintext

/**
* @author Toru Nagashima <https://github.com/mysticatea>
* See LICENSE file in root directory for full license.
*/
"use strict"
const { defineRegExpHandler } = require("../util/define-regexp-handler")
module.exports = {
meta: {
docs: {
description: "disallow RegExp Unicode property escape sequences.",
category: "ES2018",
recommended: false,
url: "http://eslint-community.github.io/eslint-plugin-es-x/rules/no-regexp-unicode-property-escapes.html",
},
fixable: null,
messages: {
forbidden:
"ES2018 RegExp Unicode property escape sequences are forbidden.",
},
schema: [],
type: "problem",
},
create(context) {
return defineRegExpHandler(context, (node) => {
let found = false
return {
onUnicodePropertyCharacterSet() {
found = true
},
onExit() {
if (found) {
context.report({ node, messageId: "forbidden" })
}
},
}
})
},
}