Skip to content

Commit

Permalink
initial commit
Browse files Browse the repository at this point in the history
  • Loading branch information
gmaclennan committed Sep 3, 2024
0 parents commit 837c488
Show file tree
Hide file tree
Showing 11 changed files with 6,617 additions and 0 deletions.
27 changes: 27 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
# Logs
logs
*.log

# Cache files
.eslintcache

# Dependency directories
node_modules/

# Build output
generated/
dist/
intermediate/

# Environment variables
.env

# IDE files
.vscode/
.idea/
*.sublime-project
*.sublime-workspace

# OS generated files
.DS_Store
Thumbs.db
1 change: 1 addition & 0 deletions .husky/pre-commit
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
npx lint-staged
1 change: 1 addition & 0 deletions .nvmrc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
20.x
18 changes: 18 additions & 0 deletions buf.gen.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
version: v2
clean: true
plugins:
- local: node_modules/ts-proto/protoc-gen-ts_proto
out: generated/proto
strategy: all
opt:
- esModuleInterop=true
- importSuffix=.js
- outputJsonMethods=false
- outputPartialMethods=false
- env=node
- useSnakeTypeName=false
- stringEnums=true
- removeEnumPrefix=true
- enumsAsLiterals=true
inputs:
- directory: proto
13 changes: 13 additions & 0 deletions buf.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# For details on buf.yaml configuration, visit https://buf.build/docs/configuration/v2/buf-yaml
version: v2
modules:
- path: proto
lint:
use:
- DEFAULT
except:
- PACKAGE_DIRECTORY_MATCH
- PACKAGE_VERSION_SUFFIX
breaking:
use:
- WIRE
99 changes: 99 additions & 0 deletions json/geometry.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,99 @@
{
"$schema": "http://json-schema.org/draft-07/schema#",
"$id": "http://comapeo.app/schemas/shared/geometry.json",
"title": "Geometry",
"description": "A subset of the GeoJSON geometry object.",
"definitions": {
"position": {
"title": "Position",
"type": "array",
"minItems": 2,
"maxItems": 2,
"items": {
"type": "number"
}
},
"linearRing": {
"title": "LinearRing",
"type": "array",
"minItems": 4,
"items": {
"$ref": "#/definitions/position"
}
}
},
"oneOf": [
{
"title": "Point",
"type": "object",
"required": ["type", "coordinates"],
"properties": {
"type": {
"type": "string",
"const": "Point"
},
"coordinates": {
"$ref": "#/definitions/position"
}
},
"additionalProperties": false
},
{
"title": "Polygon",
"type": "object",
"required": ["type", "coordinates"],
"properties": {
"type": {
"type": "string",
"const": "Polygon"
},
"coordinates": {
"type": "array",
"items": {
"$ref": "#/definitions/linearRing"
}
}
},
"additionalProperties": false
},
{
"title": "MultiPoint",
"type": "object",
"required": ["type", "coordinates"],
"properties": {
"type": {
"type": "string",
"const": "MultiPoint"
},
"coordinates": {
"type": "array",
"items": {
"$ref": "#/definitions/position"
}
}
},
"additionalProperties": false
},
{
"title": "MultiPolygon",
"type": "object",
"required": ["type", "coordinates"],
"properties": {
"type": {
"type": "string",
"const": "MultiPolygon"
},
"coordinates": {
"type": "array",
"items": {
"type": "array",
"items": {
"$ref": "#/definitions/linearRing"
}
}
}
},
"additionalProperties": false
}
]
}
Loading

0 comments on commit 837c488

Please sign in to comment.