Rabbinatix
Sign inGet started
Store

Compare prices

FreeLogic
@rabbinatix/compare-prices by Rabbinatixupdated Oct 4, 2026

Our price against theirs: cheaper, the same or more expensive.

Sign in to add

Compare gives −1, 0 or 1 (like a sort function); Switch turns each into a message.

Shows: Compare (3-way), Switch on a number.

How to use it

Add it to your logic, then add a Call Function step in any logic and pick Compare prices. It belongs to no system, so every system can use it. Or download the TypeScript and call it from your own code.

Inputs
ours: Number
theirs: Number
Outputs
verdict: Text
order: Whole number
Previewdrag the steps around; scroll to zoom
Function Entry, Input / output. 0 inputs, 3 outputs. step 1 of 6
Compare prices
ours
theirs
Compare, Operators. 2 inputs, 1 output. step 2 of 6
<=>
A
B
result
Switch, Flow control. 2 inputs, 4 outputs. step 3 of 6
Switch
value
-1
0
1
Default
Return, Input / output. 3 inputs, 0 outputs. step 4 of 6
Return
verdict
order
Return, Input / output. 3 inputs, 0 outputs. step 5 of 6
Return
verdict
order
Return, Input / output. 3 inputs, 0 outputs. step 6 of 6
Return
verdict
order

Arrow keys: next or previous step in flow order. Alt with arrows: nearest step in that direction. Enter: open. Shift F10: more actions.

100%
Examplesrun live against the logic · 3/3 pass
PassedExampleInputOutput
Cheaper{"ours":9.99,"theirs":12}{"verdict":"cheaper","order":-1}
Same{"ours":12,"theirs":12}{"verdict":"the same","order":0}
More expensive{"ours":15,"theirs":12}{"verdict":"more expensive","order":1}
Try it
Versions
In this package
Compare prices (entry)