Skip to content

Commit

Permalink
Merge 94c1d1c into e3b313a
Browse files Browse the repository at this point in the history
  • Loading branch information
Pessimistress committed Mar 7, 2024
2 parents e3b313a + 94c1d1c commit 98e2379
Show file tree
Hide file tree
Showing 33 changed files with 1,572 additions and 896 deletions.
7 changes: 5 additions & 2 deletions .eslintrc.cjs
Original file line number Diff line number Diff line change
@@ -1,8 +1,11 @@
const {getESLintConfig} = require('ocular-dev-tools/configuration');

module.exports = getESLintConfig({
react: '16.8.2',
overrides: {
overrides: {parser: '',
parserOptions: {
project: ['./tsconfig.json'],
ecmaVersion: 2020
},
env: {
browser: true,
es2020: true,
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [16, 18, 20]
node-version: [18, 20]

steps:
- uses: actions/checkout@v3.0.2
Expand Down
6 changes: 2 additions & 4 deletions .ocularrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,12 +6,10 @@ export default {
// extensions: ['js', 'md']
},

babel: {
// extensions: ['.js']
},
babel: false,

typescript: {
project: 'tsconfig.modules.json'
project: 'tsconfig.build.json'
},

aliases: {
Expand Down
17 changes: 0 additions & 17 deletions babel.config.cjs

This file was deleted.

1 change: 0 additions & 1 deletion modules/core/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,6 @@
"./src/lib/common.js"
],
"dependencies": {
"@babel/runtime": "^7.12.0",
"@math.gl/types": "4.0.0"
},
"gitHead": "e1a95300cb225a90da6e90333d4adf290f7ba501"
Expand Down
2 changes: 1 addition & 1 deletion modules/core/tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"extends": "../../tsconfig.build.json",
"extends": "../../tsconfig.module.json",
"include": ["src/**/*"],
"exclude": ["node_modules"],
"compilerOptions": {
Expand Down
1 change: 0 additions & 1 deletion modules/culling/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,6 @@
"src"
],
"dependencies": {
"@babel/runtime": "^7.12.0",
"@math.gl/core": "4.0.0"
},
"gitHead": "e1a95300cb225a90da6e90333d4adf290f7ba501"
Expand Down
2 changes: 1 addition & 1 deletion modules/culling/tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"extends": "../../tsconfig.build.json",
"extends": "../../tsconfig.module.json",
"include": ["src/**/*"],
"exclude": ["node_modules"],
"compilerOptions": {
Expand Down
1 change: 0 additions & 1 deletion modules/dggs-geohash/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,6 @@
"src"
],
"dependencies": {
"@babel/runtime": "^7.12.0",
"@math.gl/web-mercator": "4.0.0"
}
}
2 changes: 1 addition & 1 deletion modules/dggs-geohash/tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"extends": "../../tsconfig.build.json",
"extends": "../../tsconfig.module.json",
"include": ["src/**/*"],
"exclude": ["node_modules"],
"compilerOptions": {
Expand Down
1 change: 0 additions & 1 deletion modules/dggs-quadkey/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,6 @@
"src"
],
"dependencies": {
"@babel/runtime": "^7.12.0",
"@math.gl/web-mercator": "4.0.0"
}
}
2 changes: 1 addition & 1 deletion modules/dggs-quadkey/tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"extends": "../../tsconfig.build.json",
"extends": "../../tsconfig.module.json",
"include": ["src/**/*"],
"exclude": ["node_modules"],
"compilerOptions": {
Expand Down
1 change: 0 additions & 1 deletion modules/dggs-s2/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,6 @@
"src"
],
"dependencies": {
"@babel/runtime": "^7.12.0",
"long": "^5.2.1"
},
"devDependencies": {
Expand Down
2 changes: 1 addition & 1 deletion modules/dggs-s2/tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"extends": "../../tsconfig.build.json",
"extends": "../../tsconfig.module.json",
"include": ["src/**/*"],
"exclude": ["node_modules"],
"compilerOptions": {
Expand Down
1 change: 0 additions & 1 deletion modules/geoid/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,6 @@
"src"
],
"dependencies": {
"@babel/runtime": "^7.12.0",
"@math.gl/core": "4.0.0"
},
"gitHead": "e1a95300cb225a90da6e90333d4adf290f7ba501"
Expand Down
2 changes: 1 addition & 1 deletion modules/geoid/tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"extends": "../../tsconfig.build.json",
"extends": "../../tsconfig.module.json",
"include": ["src/**/*"],
"exclude": ["node_modules"],
"compilerOptions": {
Expand Down
1 change: 0 additions & 1 deletion modules/geospatial/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,6 @@
"src"
],
"dependencies": {
"@babel/runtime": "^7.12.0",
"@math.gl/core": "4.0.0"
},
"gitHead": "e1a95300cb225a90da6e90333d4adf290f7ba501"
Expand Down
2 changes: 1 addition & 1 deletion modules/geospatial/tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"extends": "../../tsconfig.build.json",
"extends": "../../tsconfig.module.json",
"include": ["src/**/*"],
"exclude": ["node_modules"],
"compilerOptions": {
Expand Down
2 changes: 1 addition & 1 deletion modules/main/tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"extends": "../../tsconfig.build.json",
"extends": "../../tsconfig.module.json",
"include": ["src/**/*"],
"exclude": ["node_modules"],
"compilerOptions": {
Expand Down
2 changes: 1 addition & 1 deletion modules/polygon/tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"extends": "../../tsconfig.build.json",
"extends": "../../tsconfig.module.json",
"include": ["src/**/*"],
"exclude": ["node_modules"],
"compilerOptions": {
Expand Down
1 change: 0 additions & 1 deletion modules/proj4/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,6 @@
"src"
],
"dependencies": {
"@babel/runtime": "^7.12.0",
"@math.gl/core": "4.0.0",
"@types/proj4": "^2.5.0",
"proj4": "2.6.2"
Expand Down
2 changes: 1 addition & 1 deletion modules/proj4/tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"extends": "../../tsconfig.build.json",
"extends": "../../tsconfig.module.json",
"include": ["src/**/*"],
"exclude": ["node_modules"],
"compilerOptions": {
Expand Down
1 change: 0 additions & 1 deletion modules/sun/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,5 @@
"src"
],
"dependencies": {
"@babel/runtime": "^7.12.0"
}
}
2 changes: 1 addition & 1 deletion modules/sun/tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"extends": "../../tsconfig.build.json",
"extends": "../../tsconfig.module.json",
"include": ["src/**/*"],
"exclude": ["node_modules"],
"compilerOptions": {
Expand Down
2 changes: 1 addition & 1 deletion modules/types/tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"extends": "../../tsconfig.build.json",
"extends": "../../tsconfig.module.json",
"include": ["src/**/*"],
"exclude": ["node_modules"],
"compilerOptions": {
Expand Down
1 change: 0 additions & 1 deletion modules/web-mercator/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,6 @@
"src"
],
"dependencies": {
"@babel/runtime": "^7.12.0"
},
"devDependencies": {
"mock-browser": "^0.92.14"
Expand Down
2 changes: 1 addition & 1 deletion modules/web-mercator/tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"extends": "../../tsconfig.build.json",
"extends": "../../tsconfig.module.json",
"include": ["src/**/*"],
"exclude": ["node_modules"],
"compilerOptions": {
Expand Down
20 changes: 5 additions & 15 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,33 +13,23 @@
"examples/*"
],
"scripts": {
"bootstrap": "PUPPETEER_SKIP_CHROMIUM_DOWNLOAD=true yarn && ocular-bootstrap",
"bootstrap": "yarn && ocular-bootstrap",
"clean": "ocular-clean",
"build": "npm run clean && time ocular-build",
"cover": "ocular-test cover",
"lint": "tsc && ocular-lint",
"metrics": "ocular-metrics",
"publish": "ocular-publish",
"test": "ocular-test",
"test-size-explicit": "npm run build && webpack --config test/webpack.config.js --env.import-vec4-mat4-explicit",
"test-size": "npm run build && webpack --config test/webpack.config.js --env.import-nothing"
"test": "ocular-test"
},
"dependencies": {},
"devDependencies": {
"@probe.gl/bench": "^4.0.0",
"@turf/destination": "^6.0.1",
"@types/tape-promise": "^4.0.1",
"babel-plugin-transform-builtin-extend": "^1.1.2",
"ocular-dev-tools": "2.0.0-alpha.9",
"pre-commit": "^1.2.2"
},
"resolutions_notes": [
"Note: tape 4.12 and higher no longer compares 0 and -0 equally...",
"es-abstract breaks on Node 18"
],
"resolutions": {
"tape": "4.11.0",
"es-abstract": "^1.21.1"
"ocular-dev-tools": "2.0.0-alpha.28",
"pre-commit": "^1.2.2",
"puppeteer": "^22.0.0"
},
"volta": {
"node": "18.18.1",
Expand Down
29 changes: 20 additions & 9 deletions tsconfig.build.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,26 @@
{
"extends": "./tsconfig.json",
"compilerOptions": {
"build": true,
"target": "es2020",
"module": "es2020",
"esModuleInterop": true,
"declaration": true,
"declarationMap": true,
"noEmit": false,
"emitDeclarationOnly": true
"build": true
// Uncomment to debug
// "listEmittedFiles": true
}
},
// Monorepo setup. All modules need to be listed here
"references": [
{"path": "modules/core"},
{"path": "modules/culling"},
{"path": "modules/dggs-geohash"},
{"path": "modules/dggs-s2"},
{"path": "modules/dggs-quadkey"},
{"path": "modules/geoid"},
{"path": "modules/geospatial"},
{"path": "modules/main"},
{"path": "modules/polygon"},
{"path": "modules/proj4"},
{"path": "modules/sun"},
{"path": "modules/web-mercator"}
],
"include": [
"modules/*/src"
]
}
5 changes: 2 additions & 3 deletions tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,8 @@
},

"compilerOptions": {
"target": "esnext",
"module": "esnext",
"jsx": "react",
"target": "es2020",
"module": "es2020",
"allowJs": true,
"checkJs": false,
"moduleResolution": "node",
Expand Down
26 changes: 26 additions & 0 deletions tsconfig.module.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
// This is the monorepo build config
// needs to be a separate file to avoid importing references into packages
{
"extends": "./tsconfig.json",
"compilerOptions": {
"build": true,
"esModuleInterop": true,
"declaration": true,
"noEmit": false,
"useDefineForClassFields": false,
// Uncomment to debug
"listEmittedFiles": true,
"plugins": [
{
"transform": "ocular-dev-tools/ts-transform-append-extension",
"extensions": [".js"],
"after": true
},
{
"transform": "ocular-dev-tools/ts-transform-append-extension",
"extensions": [".js"],
"afterDeclarations": true
}
]
}
}
41 changes: 0 additions & 41 deletions tsconfig.modules.json

This file was deleted.

Loading

0 comments on commit 98e2379

Please sign in to comment.