refactor(runtime-core): isBuiltInTag -> use makeMap instead of Set (#307)
This commit is contained in:
parent
11ea3d35d8
commit
cf12d18b4b
@ -22,7 +22,8 @@ import {
|
||||
NOOP,
|
||||
isArray,
|
||||
isObject,
|
||||
NO
|
||||
NO,
|
||||
makeMap
|
||||
} from '@vue/shared'
|
||||
import { SuspenseBoundary } from './suspense'
|
||||
import {
|
||||
@ -224,8 +225,7 @@ export const setCurrentInstance = (
|
||||
currentInstance = instance
|
||||
}
|
||||
|
||||
const BuiltInTagSet = new Set(['slot', 'component'])
|
||||
const isBuiltInTag = (tag: string) => BuiltInTagSet.has(tag)
|
||||
const isBuiltInTag = /*#__PURE__*/ makeMap('slot,component')
|
||||
|
||||
export function validateComponentName(name: string, config: AppConfig) {
|
||||
const appIsNativeTag = config.isNativeTag || NO
|
||||
|
Loading…
Reference in New Issue
Block a user