文件操作 - transform.d.mts
返回文件管理
返回主菜单
删除本文件
文件: /var/www/OLD/node_modules/unctx/dist/transform.d.mts
编辑文件内容
import MagicString from 'magic-string'; interface TransformerOptions { /** * The function names to be transformed. * * @default ['withAsyncContext'] */ asyncFunctions?: string[]; /** * @default 'unctx' */ helperModule?: string; /** * @default 'executeAsync' */ helperName?: string; /** * Whether to transform properties of an object defined with a helper function. For example, * to transform key `middleware` within the object defined with function `defineMeta`, you would pass: * `{ defineMeta: ['middleware'] }`. * @default {} */ objectDefinitions?: Record<string, string[]>; } declare function createTransformer(options?: TransformerOptions): { transform: (code: string, options_?: { force?: false; }) => { code: string; magicString: MagicString; } | undefined; shouldTransform: (code: string) => boolean; }; export { type TransformerOptions, createTransformer };
修改文件时间
将文件时间修改为当前时间的前一年
删除文件