Initial commit
This commit is contained in:
28
types/meters.ts
Normal file
28
types/meters.ts
Normal file
@@ -0,0 +1,28 @@
|
||||
/**
|
||||
* Shared type definitions for Saudi Meters data
|
||||
* Used by both frontend and backend projects
|
||||
*/
|
||||
|
||||
export interface MeterProperties {
|
||||
id: string
|
||||
maker: string
|
||||
model: string
|
||||
timestamp: string
|
||||
}
|
||||
|
||||
export interface MeterFeature {
|
||||
type: "Feature"
|
||||
geometry: {
|
||||
type: "Point"
|
||||
coordinates: [number, number]
|
||||
}
|
||||
properties: MeterProperties
|
||||
}
|
||||
|
||||
export interface MetersCollection {
|
||||
type: "FeatureCollection"
|
||||
features: MeterFeature[]
|
||||
}
|
||||
|
||||
// Type alias for convenience
|
||||
export type GeoJSONMeterData = MetersCollection
|
||||
Reference in New Issue
Block a user