Open TheBrenny opened 3 years ago
Chaining is a super handy thing, and even better is that I can chain styles and movements together and assign that chain to a variable (one of the reasons which convinced me btw! 🤩)
But while doing things like center = (str) => term.left(str.length / 2)(str) is fun and easy, I'd love to be able to assign it to the Terminal.prototype in a way where I can still chain it to other chainable functions/properties
center = (str) => term.left(str.length / 2)(str)
Terminal.prototype
That way we can start doing things like:
term.assign({ center: function(str) { return this.left(str.length / 2)(str); } })
Or something similar.
Chaining is a super handy thing, and even better is that I can chain styles and movements together and assign that chain to a variable (one of the reasons which convinced me btw! 🤩)
But while doing things like
center = (str) => term.left(str.length / 2)(str)
is fun and easy, I'd love to be able to assign it to theTerminal.prototype
in a way where I can still chain it to other chainable functions/propertiesThat way we can start doing things like:
Or something similar.