Skip to content
This repository has been archived by the owner on Jun 20, 2019. It is now read-only.

Providing duplicate directives, style URLs and providers doesn't show any warning #670

Open
ghost opened this issue Nov 30, 2018 · 1 comment

Comments

@ghost
Copy link

ghost commented Nov 30, 2018

import 'package:angular/angular.dart';
import 'package:angular_components/angular_components.dart';

@Component(
    selector: 'example-comp',
    templateUrl: 'example_comp.html',
    directives: const [
      MaterialToggleComponent,
      MaterialToggleComponent, // no warning
    ],
    styleUrls: const [
      'example_comp.scss.css',
      'example_comp.scss.css' // no warning
    ],
    providers: [
      popupBindings,
      popupBindings, // no warning
    ],
    exports: [
      ModalComponent,
      ModalComponent,// shows warning
    ])
class ExampleComp{
}

In above example providing duplicate directives, style URLs and providers doesn't show any warning.
Warnings are shown only for duplicate values in exports field.

@MichaelRFairhurst
Copy link
Contributor

This is a great feature request to detect this, thanks!! Absolutely would be useful, and shouldn't be too difficult either.

Thanks for filing and for the detailed example!

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Development

No branches or pull requests

1 participant