I\'m attempting to load an RSA private key into my nodejs application using environment variables, but the newlines seem to be being auto-escaped.
For the following, ass
I was using:
JSON.parse(`"${process.env.PUBPEM}"`)
which suddenly started to fail. So I changed it to:
JSON.parse(JSON.stringify(process.env.PUBPEM))
Which solved it for me.