Skip to content

Reuse existing import if already defined in the fileΒ #5

@RIP21

Description

@RIP21

If we move from let say packlets/utils to @acme/utils and in the file, there is already a @acme/utils imports we should add imports to it and do not create a new one.

So from:

import { fn1 } from 'packlets/utils'
import { fn2 } from '@acme/utils'

To:

import { fn2, fn1 } from '@acme/utils'

Currently it will generate following:

import { fn1 } from '@acme/utils'
import { fn2 } from '@acme/utils'

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions