ngrx / platform

Reactive State for Angular
https://ngrx.io
Other
8.01k stars 1.97k forks source link

Rename `signals` to `computed` when defining custom features with input for consistency #4391

Closed markostanimirovic closed 3 months ago

markostanimirovic commented 3 months ago

Which @ngrx/* package(s) are relevant/related to the feature request?

signals

Information

Rename signals with computed when defining custom features with input for consistent naming with withComputed feature.

function withN() {
  return signalStoreFeature(
    {
-      signals: type<{ l: Signal<number>; m: Signal<number> }>(),
+     computed: type<{ l: Signal<number>; m: Signal<number> }>(),
    },
    withComputed(({ l, m }) => ({
      n: computed(() => l() + m()),
    }))
  );
}

Describe any alternatives/workarounds you're currently using

No response

I would be willing to submit a PR to fix this issue