MCPcopy
hub / github.com/vuejs/core / ondirarg

Function ondirarg

packages/compiler-core/src/parser.ts:248–263  ·  view source on GitHub ↗
(start, end)

Source from the content-addressed store, hash-verified

246 },
247
248 ondirarg(start, end) {
249 if (start === end) return
250 const arg = getSlice(start, end)
251 if (inVPre && !isVPre(currentProp!)) {
252 ;(currentProp as AttributeNode).name += arg
253 setLocEnd((currentProp as AttributeNode).nameLoc, end)
254 } else {
255 const isStatic = arg[0] !== `[`
256 ;(currentProp as DirectiveNode).arg = createExp(
257 isStatic ? arg : arg.slice(1, -1),
258 isStatic,
259 getLoc(start, end),
260 isStatic ? ConstantTypes.CAN_STRINGIFY : ConstantTypes.NOT_CONSTANT,
261 )
262 }
263 },
264
265 ondirmodifier(start, end) {
266 const mod = getSlice(start, end)

Callers

nothing calls this directly

Calls 5

isVPreFunction · 0.90
getSliceFunction · 0.85
setLocEndFunction · 0.85
createExpFunction · 0.85
getLocFunction · 0.85

Tested by

no test coverage detected