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

Pipe & Uglify #152

Open
Mattchewone opened this issue Feb 19, 2016 · 4 comments
Open

Pipe & Uglify #152

Mattchewone opened this issue Feb 19, 2016 · 4 comments
Labels

Comments

@Mattchewone
Copy link

I am currently using browserify and babel to build my app which is working fine in conjunction with browsersync.

I tried to add in uglify which ran fine but when I loaded the app, I had issues with an @pipe saying it could not find the provider. I have the following:

...
import { filter } from '../../../filters/filter';
@Component({
  selector: 'app-thing',
  pipes: [filter],
  inputs: ['input'],
  template: template,
  providers: [
   ...
  ]
})
...

Any ideas?
Thanks

@timkindberg
Copy link
Contributor

Could you post the exact error message?

@Mattchewone
Copy link
Author

Sure, it builds fine in gulp but when I load in the browser Angular throws this:

Error: [$injector:unpr] Unknown provider: filterProvider <- filter

@david-gang
Copy link
Contributor

Hi,

I have the same problem.
The issue is that the string name of the filter is directly taken from the metastore and therefore it cannot be uglified.

$translate <- e32 <- e8848
We don't have selectors here which compensate.

Thanks,
David

@Mattchewone
Copy link
Author

I assume there is no way to annotate it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants