MCPcopy
hub / github.com/vitejs/vite / post

Function post

packages/plugin-legacy/src/index.ts:1037–1044  ·  view source on GitHub ↗
({ path })

Source from the content-addressed store, hash-verified

1035 return ({ types: t }: { types: typeof BabelTypes }): BabelPlugin => ({
1036 name: 'vite-remove-polyfill-import',
1037 post({ path }) {
1038 path.get('body').forEach((p) => {
1039 if (t.isImportDeclaration(p.node)) {
1040 polyfills.add(p.node.source.value)
1041 p.remove()
1042 }
1043 })
1044 },
1045 })
1046}
1047

Callers

nothing calls this directly

Calls 2

addMethod · 0.80
getMethod · 0.45

Tested by

no test coverage detected