© 2026 Hedgehog Software, LLC
Record<string, unknown>[]
const json: unknown = parser.parse(Buffer.from(xmlContent)); const cleanedData = yield* pipe( json, Schema.decodeUnknownEither(XmlSchema, { onExcessProperty: "preserve", }), Effect.andThen((x) => x["d2:payload"]["egi:energyInfrastructureTable"]), Effect.andThen(A.map(Record.mapKeys((k) => k.replace("fac:", "")))) ); yield* Console.log(cleanedData); })