Referential transparency

  • it implies that functions consistently yield the same results given the same input, irrespective of where and when they are invoked.

    • That is, function evaluation depends less—ideally, not at all—on the side effects of mutable state

  • This is a property of immutability

    • we get an object and we expect it not to change

Last updated

Was this helpful?