MCPcopy Create free account
hub / github.com/Necriso/ScriptableWidgets / formatValue

Function formatValue

tankstellenpreisev2_beta.js:132–139  ·  view source on GitHub ↗
(value)

Source from the content-addressed store, hash-verified

130}
131
132function formatValue(value) {
133 if (!value) {
134 return '-'
135 }
136 let lastDigit = '⁹'
137 let price = value.toString().slice(0, -1)
138 return price + lastDigit + "€"
139}
140
141async function createWidget(data) {
142 const attr = data.stations[0]

Callers 1

createWidgetFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected