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 async pipe support #180

Open
Adrian1907 opened this issue Jun 7, 2022 · 3 comments
Open

Add async pipe support #180

Adrian1907 opened this issue Jun 7, 2022 · 3 comments
Labels
Hacktoberfest help wanted Extra attention is needed

Comments

@Adrian1907
Copy link

Describe the feature you'd like:

I would like to have a possibility to use windowed-observable directly in a html-template via async pipe.

@luistak
Copy link
Owner

luistak commented Jun 7, 2022

Hi @Adrian1907 thanks for your issue, but could you elaborate on the request with a few examples, suggestions of API, and usages?

@Adrian1907
Copy link
Author

Adrian1907 commented Jun 7, 2022

Hi @luistak, the build-in async pipe allows to use asyncronuous things like Observable or Promise in a template.
Source: https://angular.io/api/common/AsyncPipe
It would be nice to have a possibility to use windowed-observable the same way as usual observable and not only with subscribe. For example the next way:

import { Observable as WindowedObservable } from 'windowed-observable';

@Component({
  selector: 'my-selector',
  template: '<div>{{ myWindowedObservable | async }}</div>'
})
export class ExampleComponent {
  myWindowedObservable = new WindowedObservable('myNameSpace');
}

@luistak luistak added the help wanted Extra attention is needed label Jan 2, 2023
@jsanta
Copy link

jsanta commented Jul 27, 2023

@Adrian1907 I know my message comes kind of late. Did you try wrapping windowObservable in a the RXJS from() ? Don't know if it will work, but I think there's a slight chance.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Hacktoberfest help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

3 participants