fulls1z3 / ngx-meta

Dynamic page title & meta tags utility for Angular (w/server-side rendering)
MIT License
333 stars 47 forks source link

meta tags API call fails #185

Closed yura-moryliak closed 4 years ago

yura-moryliak commented 6 years ago

I'm submitting a ... (check one with "x")

[ ] Regression (a behavior that used to work and stopped working in a new release)
[ x] Bug report  <!-- Please check the repository for a similar issue or PR before submitting -->
[ ] Support request => <!-- Please check the repository for a similar issue or PR before submitting -->
[ ] Feature request
[ ] Documentation issue or request

Current behavior

Expected/desired behavior

Minimal reproduction of the problem with instructions

What is the motivation / use case for changing the behavior?

Environment

The reason i opened this issue, is that there is exist a small bug for programmatic setTag

Explanation:

When i'm calling API server to fetch data, for example for user data, i'm trying to set tags as description and og:description

And i'm facing problem, there is no existing metaTags in source code for settled meta tags

I opened issue on stackoverflow and i attach link here for my question https://stackoverflow.com/questions/52094471/angular-6-ssr-ngx-meta-live-server

I tried to use also resolver but with no success

in example of this librariy there is example how to set tags programmatically

ngOnInit() { this.item = //HTTP GET for "item" in the repository this.meta.setTitle(Page for ${this.item.name}); this.meta.setTag('og:image', this.item.imageUrl); }

And the last note: All code is working great on localost:4000 handled by SSR express server But after deploying application on Heroku server it does not work as expected

SonicReal commented 5 years ago

Same problem...

junaidbinsarfraz commented 5 years ago

Same problem. Any update on it ?