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

Function createPropsRestProxy

packages/runtime-core/src/apiSetupHelpers.ts:495–509  ·  view source on GitHub ↗
(
  props: any,
  excludedKeys: string[],
)

Source from the content-addressed store, hash-verified

493 * @internal
494 */
495export function createPropsRestProxy(
496 props: any,
497 excludedKeys: string[],
498): Record<string, any> {
499 const ret: Record<string, any> = {}
500 for (const key in props) {
501 if (!excludedKeys.includes(key)) {
502 Object.defineProperty(ret, key, {
503 enumerable: true,
504 get: () => props[key],
505 })
506 }
507 }
508 return ret
509}
510
511/**
512 * `<script setup>` helper for persisting the current instance context over

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected