Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Upgrade dev tools #26

Merged
merged 3 commits into from
Aug 27, 2024
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .eslintignore
Original file line number Diff line number Diff line change
Expand Up @@ -3,3 +3,4 @@ dist/
coverage/
test/
*.md
**/wip/
10 changes: 2 additions & 8 deletions .eslintrc.cjs
Original file line number Diff line number Diff line change
@@ -1,17 +1,12 @@
const {getESLintConfig} = require('ocular-dev-tools/configuration');
const {getESLintConfig} = require('@vis.gl/dev-tools/configuration');

module.exports = getESLintConfig({
overrides: {parser: '',
parserOptions: {
project: ['./tsconfig.json'],
ecmaVersion: 2020
},
overrides: {
env: {
browser: true,
es2020: true,
node: true
},

overrides: [
{
// scripts use devDependencies
Expand All @@ -26,7 +21,6 @@ module.exports = getESLintConfig({
files: ['modules/**/*.ts', 'modules/**/*.js'],
rules: {
'no-use-before-define': 0,
'import/no-unresolved': 0,
'import/named': 0,
'@typescript-eslint/ban-ts-comment': 0 // We do need our ts-ignores
}
Expand Down
10 changes: 2 additions & 8 deletions .ocularrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,8 @@ import {resolve} from 'path';

export default {
lint: {
paths: ['dev-docs', 'docs', 'modules', 'examples', 'test'] // 'website'
// extensions: ['js', 'md']
},

babel: false,

typescript: {
project: 'tsconfig.build.json'
paths: ['dev-docs', 'docs', 'modules', 'examples', 'test'], // 'website'
extensions: ['js', 'mjs', 'jsx', 'ts', 'tsx', 'd.ts', 'md']
},

aliases: {
Expand Down
3 changes: 0 additions & 3 deletions .prettierrc.cjs

This file was deleted.

7 changes: 0 additions & 7 deletions Dockerfile

This file was deleted.

7 changes: 0 additions & 7 deletions docker-compose.yml

This file was deleted.

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.module.json",
"extends": "../../tsconfig.json",
"include": ["src/**/*"],
"exclude": ["node_modules"],
"compilerOptions": {
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.module.json",
"extends": "../../tsconfig.json",
"include": ["src/**/*"],
"exclude": ["node_modules"],
"compilerOptions": {
Expand Down
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.module.json",
"extends": "../../tsconfig.json",
"include": ["src/**/*"],
"exclude": ["node_modules"],
"compilerOptions": {
Expand Down
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.module.json",
"extends": "../../tsconfig.json",
"include": ["src/**/*"],
"exclude": ["node_modules"],
"compilerOptions": {
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.module.json",
"extends": "../../tsconfig.json",
"include": ["src/**/*"],
"exclude": ["node_modules"],
"compilerOptions": {
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.module.json",
"extends": "../../tsconfig.json",
"include": ["src/**/*"],
"exclude": ["node_modules"],
"compilerOptions": {
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.module.json",
"extends": "../../tsconfig.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.module.json",
"extends": "../../tsconfig.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.module.json",
"extends": "../../tsconfig.json",
"include": ["src/**/*"],
"exclude": ["node_modules"],
"compilerOptions": {
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.module.json",
"extends": "../../tsconfig.json",
"include": ["src/**/*"],
"exclude": ["node_modules"],
"compilerOptions": {
Expand Down
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.module.json",
"extends": "../../tsconfig.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.module.json",
"extends": "../../tsconfig.json",
"include": ["src/**/*"],
"exclude": ["node_modules"],
"compilerOptions": {
Expand Down
4 changes: 2 additions & 2 deletions modules/web-mercator/tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
{
"extends": "../../tsconfig.module.json",
"extends": "../../tsconfig.json",
"include": ["src/**/*"],
"exclude": ["node_modules"],
"compilerOptions": {
"noImplicitAny": false, // gl-matrix is a mess...
"noImplicitAny": false,
"composite": true,
"rootDir": "src",
"outDir": "dist"
Expand Down
3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,8 @@
"@probe.gl/bench": "^4.0.0",
"@turf/destination": "^6.0.1",
"@types/tape-promise": "^4.0.1",
"ocular-dev-tools": "2.0.0-alpha.34",
"@vis.gl/dev-tools": "1.0.0-alpha.7",
"@vis.gl/ts-plugins": "1.0.0-alpha.7",
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is there a usability advantage to requiring apps to manage two separate imports? Or could dev-tools depend on/re-export ts-plugins directly?

"pre-commit": "^1.2.2",
"puppeteer": "^22.0.0",
"tap-spec": "^5.0.0"
Expand Down
27 changes: 0 additions & 27 deletions tsconfig.build.json

This file was deleted.

16 changes: 14 additions & 2 deletions tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@
"moduleResolution": "node",
"esModuleInterop": true,
"allowSyntheticDefaultImports": true,
"noEmit": true,
"baseUrl": ".",
"useDefineForClassFields": false,

// BEGIN TYPE CHECK SETTINGS
"skipLibCheck": true,
Expand Down Expand Up @@ -64,7 +64,19 @@
"@math.gl/web-mercator/*": ["modules/web-mercator/src/*"],
"@math.gl/web-mercator/test/*": ["modules/web-mercator/test/*"],
"test/*": ["test/*"]
}
},
"plugins": [
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could this be managed with some "extend": "..." syntax so that we don't need to duplicate this everywhere?

{
"transform": "@vis.gl/ts-plugins/ts-transform-append-extension",
"extensions": [".js"],
"after": true
},
{
"transform": "@vis.gl/ts-plugins/ts-transform-append-extension",
"extensions": [".js"],
"afterDeclarations": true
}
]
},
"include":[
"modules/*/src",
Expand Down
26 changes: 0 additions & 26 deletions tsconfig.module.json

This file was deleted.

Loading
Loading