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

feat(rxjs): create a set of rxjs operators #66

Merged
merged 1 commit into from
Sep 18, 2023

Conversation

tomalaforge
Copy link
Collaborator

closing issue #41

Copy link
Collaborator

@nartc nartc left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for your contribution. A couple of nits

@@ -0,0 +1,22 @@
---
title: filter nil RxJs operator
description: ngxtension/filter-array
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: wrong description>?

import { map, pipe } from 'rxjs';

export const filterArray = <T>(filterFn: (item: T) => boolean) => {
return pipe(map((array: T[]) => array.filter((item) => filterFn(item))));
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

suggestion: I'm pretty sure pipe() isn't needed.

import { filter, pipe } from 'rxjs';

export const filterNil = <T>() =>
pipe(
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

suggestion: pipe() isn't needed

import { map, pipe } from 'rxjs';

export const mapArray = <T, R>(mapFn: (item: T) => R) => {
return pipe(map((array: T[]) => array.map((item) => mapFn(item))));
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

suggestion: pipe() isn't needed

Comment on lines 43 to 46
"libs/ngxtension/filter-array/**/*.ts",
"libs/ngxtension/filter-array/**/*.html",
"libs/ngxtension/filter-nil/**/*.ts",
"libs/ngxtension/filter-nil/**/*.html"
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

comment: remove these

@nartc
Copy link
Collaborator

nartc commented Sep 18, 2023

@all-contributors please add @tomalaforge for code

@allcontributors
Copy link
Contributor

@nartc

I've put up a pull request to add @tomalaforge! 🎉

@nx-cloud
Copy link

nx-cloud bot commented Sep 18, 2023

☁️ Nx Cloud Report

CI is running/has finished running commands for commit a074b12. As they complete they will appear below. Click to see the status, the terminal output, and the build insights.

📂 See all runs for this branch


✅ Successfully ran 4 targets

Sent with 💌 from NxCloud.

@tomalaforge tomalaforge force-pushed the feature/rxjs-operators branch from b70a190 to a074b12 Compare September 18, 2023 14:37
@tomalaforge
Copy link
Collaborator Author

thanks @nartc for reviewing my PR.

Changes made

@nartc nartc merged commit b503134 into ngxtension:main Sep 18, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants