From 3858f4541ebce87f55b528625b33ff99c77fdd76 Mon Sep 17 00:00:00 2001 From: afc163 Date: Fri, 22 Nov 2019 17:04:41 +0800 Subject: [PATCH 01/11] fix: eslint missing in devDependencies --- package.json | 1 + 1 file changed, 1 insertion(+) diff --git a/package.json b/package.json index 7f226caf61..c0e079cbbe 100644 --- a/package.json +++ b/package.json @@ -56,6 +56,7 @@ "enzyme": "^3.6.0", "enzyme-adapter-react-16": "^1.5.0", "enzyme-to-json": "^3.0.0-beta6", + "eslint": "^6.6.0", "eslint-config-egg": "^7.5.1", "eslint-plugin-html": "^6.0.0", "gatsby": "^2.17.7", From 903af5726a352bb065c4b44901e22c91e1e03027 Mon Sep 17 00:00:00 2001 From: afc163 Date: Fri, 22 Nov 2019 17:05:22 +0800 Subject: [PATCH 02/11] test: fix babel-preset-gatsby error in travisci --- .travis.yml | 19 +++++++++---------- babel.config.js | 2 ++ 2 files changed, 11 insertions(+), 10 deletions(-) diff --git a/.travis.yml b/.travis.yml index 01859d3e6e..7807ea6d3d 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,15 +1,14 @@ -sudo: false language: node_js + node_js: -- '12' + - '12' + env: - matrix: - - TEST_TYPE=ci - - NODE_ENV=test -branches: - only: - - master + - NODE_ENV=test + install: -- yarn install + - yarn install + script: -- yarn run lint + - yarn lint + - yarn test diff --git a/babel.config.js b/babel.config.js index 9cd7ba068b..ca6abef2c6 100644 --- a/babel.config.js +++ b/babel.config.js @@ -5,6 +5,7 @@ module.exports = api => { const isCommonJS = api.env('cjs'); const isESModule = api.env('esm'); const isTest = api.env('test'); + if (process.env.GATSBY === 'true') { // return { presets: [ @@ -33,6 +34,7 @@ module.exports = api => { ] }; } + return { presets: [ [ From 12d6893cd64c30e46793de78dbc357a798e5d6c8 Mon Sep 17 00:00:00 2001 From: afc163 Date: Fri, 22 Nov 2019 17:14:33 +0800 Subject: [PATCH 03/11] chore: remove NODE_ENV=site and allow using tnpm in yarn mode --- package.json | 3 +++ 1 file changed, 3 insertions(+) diff --git a/package.json b/package.json index c0e079cbbe..27508ff1c3 100644 --- a/package.json +++ b/package.json @@ -158,5 +158,8 @@ "commitizen": { "path": "cz-conventional-changelog" } + }, + "tnpm": { + "mode": "yarn" } } From c5e1c4e22f1f6dd7cc2bfb1f595a905ef6134873 Mon Sep 17 00:00:00 2001 From: afc163 Date: Fri, 22 Nov 2019 18:04:55 +0800 Subject: [PATCH 04/11] chore: add .yarnrc --- .yarnrc | 2 ++ 1 file changed, 2 insertions(+) create mode 100644 .yarnrc diff --git a/.yarnrc b/.yarnrc new file mode 100644 index 0000000000..80abab4273 --- /dev/null +++ b/.yarnrc @@ -0,0 +1,2 @@ +env: + SASS_BINARY_SITE "https://npm.taobao.org/mirrors/node-sass/" From 16539f61de2c50de103777177f1eca4a198c8d8f Mon Sep 17 00:00:00 2001 From: afc163 Date: Fri, 22 Nov 2019 18:23:55 +0800 Subject: [PATCH 05/11] chore: add badges in README --- README.md | 7 +++---- README.zh.md | 5 +++-- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/README.md b/README.md index efb1985540..78ee30ee84 100644 --- a/README.md +++ b/README.md @@ -1,9 +1,8 @@ -# L7 +# L7 -![最近提交](https://badgen.net/github/last-commit/antvis/L7) - -L7 Large-scale WebGL-powered Geospatial data visualization analysis framework +[]![travis ci](https://travis-ci.com/antvis/L7.svg?branch=master)](https://travis-ci.com/antvis/L7) [![](https://flat.badgen.net/npm/v/@antv/l7?icon=npm)](https://www.npmjs.com/package/@antv/l7) ![最近提交](https://badgen.net/github/last-commit/antvis/L7) +Large-scale WebGL-powered Geospatial data visualization analysis framework. ## l7 visualization demos diff --git a/README.zh.md b/README.zh.md index 2b1281786e..2699c4c256 100644 --- a/README.zh.md +++ b/README.zh.md @@ -1,7 +1,8 @@ ## L7 地理空间数据可视分析引擎 -L7 是由蚂蚁金服 AntV 数据可视化团队推出的基于 WebGL 的开源大规模地理空间数据可视分析开发框架。L7 中的 L 代表 Location,7 代表世界七大洲,寓意能为全球位置数据提供可视分析的能力。L7 以图形符号学为理论基础,将抽象复杂的空间数据转化成 2D、3D 符号,通过颜色、大小、体积、纹理等视觉变量实现丰富的可视化表达。 +[]![travis ci](https://travis-ci.com/antvis/L7.svg?branch=master)](https://travis-ci.com/antvis/L7) [![](https://flat.badgen.net/npm/v/@antv/l7?icon=npm)](https://www.npmjs.com/package/@antv/l7) ![最近提交](https://badgen.net/github/last-commit/antvis/L7) +L7 是由蚂蚁金服 AntV 数据可视化团队推出的基于 WebGL 的开源大规模地理空间数据可视分析开发框架。L7 中的 L 代表 Location,7 代表世界七大洲,寓意能为全球位置数据提供可视分析的能力。L7 以图形符号学为理论基础,将抽象复杂的空间数据转化成 2D、3D 符号,通过颜色、大小、体积、纹理等视觉变量实现丰富的可视化表达。 ## l7 visualization demos @@ -37,7 +38,7 @@ L7 是由蚂蚁金服 AntV 数据可视化团队推出的基于 WebGL 的开源 ## 支持丰富的图表类型 ### 点图层 - + - 气泡图 - 散点图 - 符号地图 From 7524f09ff8ad4e5849f67252ce678ef95e46b350 Mon Sep 17 00:00:00 2001 From: afc163 Date: Fri, 22 Nov 2019 18:28:18 +0800 Subject: [PATCH 06/11] test: update travis node version --- .travis.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index 7807ea6d3d..53cd2aa56c 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,7 +1,7 @@ language: node_js node_js: - - '12' + - '10' env: - NODE_ENV=test From 6cffd33799b6d440757df3b547c23142307dff25 Mon Sep 17 00:00:00 2001 From: afc163 Date: Fri, 22 Nov 2019 18:46:55 +0800 Subject: [PATCH 07/11] test: use latest version of yarn in travis --- .travis.yml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.travis.yml b/.travis.yml index 53cd2aa56c..2ae6c9ce8d 100644 --- a/.travis.yml +++ b/.travis.yml @@ -6,6 +6,10 @@ node_js: env: - NODE_ENV=test +before_install: + - curl -o- -L https://yarnpkg.com/install.sh | bash + - export PATH="$HOME/.yarn/bin:$PATH" + install: - yarn install From b963532ed9e999bef6000b6b51dd35c7cffb3f73 Mon Sep 17 00:00:00 2001 From: afc163 Date: Fri, 22 Nov 2019 19:00:05 +0800 Subject: [PATCH 08/11] test: revert node version --- .travis.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index 2ae6c9ce8d..b76b3aced9 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,7 +1,7 @@ language: node_js node_js: - - '10' + - '12' env: - NODE_ENV=test From aff005262723df6c1bee03364020f80778e60623 Mon Sep 17 00:00:00 2001 From: afc163 Date: Fri, 22 Nov 2019 19:02:43 +0800 Subject: [PATCH 09/11] test: skip test case in travis --- packages/renderer/src/regl/__tests__/model.spec.ts | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/packages/renderer/src/regl/__tests__/model.spec.ts b/packages/renderer/src/regl/__tests__/model.spec.ts index 8f81b4b175..fa86ef3973 100644 --- a/packages/renderer/src/regl/__tests__/model.spec.ts +++ b/packages/renderer/src/regl/__tests__/model.spec.ts @@ -1,13 +1,14 @@ import 'reflect-metadata'; import regl from 'regl'; import ReglModel from '../ReglModel'; -import createContext from './utils/create-context'; -describe('ReglModel', () => { +// TODO: 暂时在 travis 跳过这个测试用例,本地能跑过 +(process.env.NODE_ENV === 'test' ? describe.skip : describe)('ReglModel', () => { let gl; let reGL: regl.Regl; beforeEach(() => { + const createContext = require('./utils/create-context').default; gl = createContext(1, 1); reGL = regl(gl); }); From 52e8afcb345151f4e544a4227590e6eebd7b42bd Mon Sep 17 00:00:00 2001 From: afc163 Date: Fri, 22 Nov 2019 19:53:17 +0800 Subject: [PATCH 10/11] fix: eslint bug --- packages/renderer/src/regl/__tests__/model.spec.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/packages/renderer/src/regl/__tests__/model.spec.ts b/packages/renderer/src/regl/__tests__/model.spec.ts index fa86ef3973..6b5703e1f4 100644 --- a/packages/renderer/src/regl/__tests__/model.spec.ts +++ b/packages/renderer/src/regl/__tests__/model.spec.ts @@ -3,7 +3,9 @@ import regl from 'regl'; import ReglModel from '../ReglModel'; // TODO: 暂时在 travis 跳过这个测试用例,本地能跑过 -(process.env.NODE_ENV === 'test' ? describe.skip : describe)('ReglModel', () => { +const describeFn = process.env.NODE_ENV === 'test' ? describe.skip : describe; + +describeFn('ReglModel', () => { let gl; let reGL: regl.Regl; From 31c98a7a59b626009d77f903fc425d98289281c7 Mon Sep 17 00:00:00 2001 From: afc163 Date: Fri, 22 Nov 2019 21:54:21 +0800 Subject: [PATCH 11/11] docs: fix mixed contents --- docs/api/l7.en.md | 2 +- docs/api/l7.zh.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/api/l7.en.md b/docs/api/l7.en.md index c372d192a0..f5a260d390 100644 --- a/docs/api/l7.en.md +++ b/docs/api/l7.en.md @@ -13,7 +13,7 @@ L7 是由蚂蚁金服 AntV 数据可视化团队推出的基于 WebGL 的开源 diff --git a/docs/api/l7.zh.md b/docs/api/l7.zh.md index 1ddcceae71..f52a38a734 100644 --- a/docs/api/l7.zh.md +++ b/docs/api/l7.zh.md @@ -18,7 +18,7 @@ L7 是由蚂蚁金服 AntV 数据可视化团队推出的基于 WebGL 的开源