Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add loose mode #14

Open
timocov opened this issue Aug 15, 2020 · 0 comments
Open

Add loose mode #14

timocov opened this issue Aug 15, 2020 · 0 comments
Labels
enhancement New feature or request
Milestone

Comments

@timocov
Copy link
Owner

timocov commented Aug 15, 2020

Currently the transformer trying to figure out visibility type of every particular node, what allows minify properties better.

Needs to add "loose" mode, what will use the only name of the property (rather that type/symbol) to detect visibility type.

For example,

export interface Foo {
  prop: number;
}

export class Bar implements Foo {
  prop: number = 123;
}

class Baz {
  prop: number = 321;
}

In the current mode we'll rename Baz::prop to Baz::_internal_prop, but Bar::prop will be unchanged.

In "loose" mode we won't rename Baz::prop, because there is another "public" property with the same name prop (but in Bar class). So, we'll just pop-up all "public" properties and use that set of names only.

@timocov timocov added the enhancement New feature or request label Aug 15, 2020
@timocov timocov added this to the 1.0 milestone Aug 15, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant