I don't think my link mentions using </> button, but I did think OP knew this, as his js code is posted correctly.
@riddertommie here is a join example with no context
[{"id":"51baa685a0efa654","type":"inject","z":"3d3ac876aebd8472","name":"","props":[{"p":"payload"}],"repeat":"60","crontab":"","once":true,"onceDelay":"5","topic":"","payload":"","payloadType":"date","x":150,"y":540,"wires":[["598eee99d92290b9","537c9b9708543493","cd142b43a9c0c375","ed6aae5687ab99d2"]]},{"id":"598eee99d92290b9","type":"api-current-state","z":"3d3ac876aebd8472","name":"Get production_tarif1","server":"8c12cc5593f9646e","version":3,"outputs":1,"halt_if":"","halt_if_type":"str","halt_if_compare":"is","entity_id":"sensor.production_tarif1","state_type":"str","blockInputOverrides":false,"outputProperties":[{"property":"payload","propertyType":"msg","value":"","valueType":"entityState"}],"for":"0","forType":"num","forUnits":"minutes","override_topic":false,"state_location":"payload","override_payload":"msg","entity_location":"data","override_data":"msg","x":420,"y":540,"wires":[["7ac52375126756ec"]]},{"id":"537c9b9708543493","type":"api-current-state","z":"3d3ac876aebd8472","name":"Get production_tarif2","server":"8c12cc5593f9646e","version":3,"outputs":1,"halt_if":"","halt_if_type":"str","halt_if_compare":"is","entity_id":"sensor.production_tarif2","state_type":"str","blockInputOverrides":false,"outputProperties":[{"property":"payload","propertyType":"msg","value":"","valueType":"entityState"}],"for":"0","forType":"num","forUnits":"minutes","override_topic":false,"state_location":"payload","override_payload":"msg","entity_location":"data","override_data":"msg","x":420,"y":600,"wires":[["c21d3b73b37e1446"]]},{"id":"cd142b43a9c0c375","type":"api-current-state","z":"3d3ac876aebd8472","name":"Get consumption_tarif1","server":"8c12cc5593f9646e","version":3,"outputs":1,"halt_if":"","halt_if_type":"str","halt_if_compare":"is","entity_id":"sensor.consumption_tarif1","state_type":"str","blockInputOverrides":false,"outputProperties":[{"property":"payload","propertyType":"msg","value":"","valueType":"entityState"}],"for":"0","forType":"num","forUnits":"minutes","override_topic":false,"state_location":"payload","override_payload":"msg","entity_location":"data","override_data":"msg","x":430,"y":660,"wires":[["f0996d22acc979d4"]]},{"id":"ed6aae5687ab99d2","type":"api-current-state","z":"3d3ac876aebd8472","name":"Get consumption_tarif1","server":"8c12cc5593f9646e","version":3,"outputs":1,"halt_if":"","halt_if_type":"str","halt_if_compare":"is","entity_id":"sensor.consumption_tarif2","state_type":"str","blockInputOverrides":false,"outputProperties":[{"property":"payload","propertyType":"msg","value":"","valueType":"entityState"}],"for":"0","forType":"num","forUnits":"minutes","override_topic":false,"state_location":"payload","override_payload":"msg","entity_location":"data","override_data":"msg","x":430,"y":720,"wires":[["b54dbb9ab83c8da4"]]},{"id":"7ac52375126756ec","type":"change","z":"3d3ac876aebd8472","name":"production_tarif1","rules":[{"t":"set","p":"topic","pt":"msg","to":"production_tarif1","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":670,"y":540,"wires":[["0525f009e6dda23f"]]},{"id":"c21d3b73b37e1446","type":"change","z":"3d3ac876aebd8472","name":"production_tarif2","rules":[{"t":"set","p":"topic","pt":"msg","to":"production_tarif2","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":670,"y":600,"wires":[["0525f009e6dda23f"]]},{"id":"f0996d22acc979d4","type":"change","z":"3d3ac876aebd8472","name":"consumption_tarif1","rules":[{"t":"set","p":"topic","pt":"msg","to":"consumption_tarif1","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":670,"y":660,"wires":[["0525f009e6dda23f"]]},{"id":"b54dbb9ab83c8da4","type":"change","z":"3d3ac876aebd8472","name":"consumption_tarif2","rules":[{"t":"set","p":"topic","pt":"msg","to":"consumption_tarif2","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":670,"y":720,"wires":[["0525f009e6dda23f"]]},{"id":"0525f009e6dda23f","type":"join","z":"3d3ac876aebd8472","name":"","mode":"custom","build":"object","property":"payload","propertyType":"msg","key":"topic","joiner":"\\n","joinerType":"str","accumulate":false,"timeout":"","count":"4","reduceRight":false,"reduceExp":"","reduceInit":"","reduceInitType":"","reduceFixup":"","x":910,"y":620,"wires":[["e9ba902d7ff71e91"]]},{"id":"e9ba902d7ff71e91","type":"function","z":"3d3ac876aebd8472","name":"","func":"var tarif1 = msg.consumption_tarif1;\nvar tarif2 = msg.consumption_tarif2;\nvar tarif3 = msg.production_tarif1;\nvar tarif4 = msg.production_tarif2;\n\nlet c1 = parseFloat(tarif1);\nlet c2 = parseFloat(tarif2);\nlet p1 = parseFloat(tarif3);\nlet p2 = parseFloat(tarif4);\n\nvar consumption = (c1 + c2);\nvar production = (p1 + p2);\nvar gtt = (consumption - production).toFixed(2);\n\n//msg.payload = price;\n\nmsg.payload = {\n // \"text\": value + ' KW', \n \"text\": gtt + ' ' + 'kWh',\n \"icon\": 32930,\n \"repeat\": 1,\n \"pushIcon\": 0\n};\n\nnode.status({ fill: 'green', shape: 'ring', text: gtt + ' ' + 'kWh' });\n\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":920,"y":540,"wires":[["1c7e2e601b6ef29b","6f96734b1b49efb4"]]},{"id":"1c7e2e601b6ef29b","type":"debug","z":"3d3ac876aebd8472","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":1110,"y":660,"wires":[]},{"id":"6f96734b1b49efb4","type":"mqtt out","z":"3d3ac876aebd8472","name":"","topic":"awtrix_6ffae0/custom/power_usage","qos":"","retain":"","respTopic":"","contentType":"","userProps":"","correl":"","expiry":"","broker":"ab43d7d9dd038e9e","x":1200,"y":540,"wires":[]},{"id":"ab43d7d9dd038e9e","type":"mqtt-broker","name":"Mosqitto","broker":"192.168.2.203","port":"1883","clientid":"","autoConnect":true,"usetls":false,"protocolVersion":"4","keepalive":"60","cleansession":true,"birthTopic":"","birthQos":"0","birthPayload":"","birthMsg":{},"closeTopic":"","closeQos":"0","closePayload":"","closeMsg":{},"willTopic":"","willQos":"0","willPayload":"","willMsg":{},"userProps":"","sessionExpiry":""}]
Untested as I do not have HA installed.