Rewrite the code from OOP to FP. Suppose that you need to get Demo(p1) having no values for p2 and p3 in that place of code.

class Demo {
  constructor(p1, p2, p3) {
    this.p1 = p1
    this.p2 = p2
    this.p3 = p3
  }

  foo(p4, p5) { ... }
  bar(p4, p5) { ... }
}

// Your actions are limited to:

// now
let d = Demo(p1, p2, p3)

// later
d.foo(p4, p5)
d.bar(p4, p5)