Open twilkinson3421 opened 2 months ago
The removeUnusedImports setting is causing used imports to be removed, in my experience, where the following is the case:
removeUnusedImports
export const FieldHelp = Interface.Methods.createComponent< React.ElementRef<typeof Tooltip.Trigger>, React.ComponentPropsWithoutRef<typeof Tooltip.Trigger>, typeof fieldHelpVariants, {} >({ debugName: "FieldHelp", Component: ({ children, className, ...props }, ref) => { const { help } = useFormFieldContext(); return ( <Tooltip.Root> //... ); }; });
In a file like the above, useFormFieldContext will be removed from the imports even though it is being used.
useFormFieldContext
Interface
Interface.createComponent
field.tsx
submit.tsx
The
removeUnusedImports
setting is causing used imports to be removed, in my experience, where the following is the case:In a file like the above,
useFormFieldContext
will be removed from the imports even though it is being used.Interface
is a custom namespaceInterface.createComponent
methodfield.tsx
, but not in a file calledsubmit.tsx