Skip to content

Commit

Permalink
update workflows to remove lint from build / test
Browse files Browse the repository at this point in the history
  • Loading branch information
Parker-Stafford committed Apr 30, 2024
1 parent dbe3108 commit 05b3e7b
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 12 deletions.
23 changes: 16 additions & 7 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
@@ -1,9 +1,24 @@
name: CI
on: [push]
jobs:
ci:
name: Lint TypeScript
runs-on: ubuntu-latest
steps:
- name: Checkout Repository
uses: actions/checkout@v3
- name: Set up Nodejs
uses: actions/setup-node@v3
with:
node-version: 18
- name: Install deps and build (with cache)
uses: bahmutov/npm-install@v1
- name: Lint
run: yarn lint
- name: Prettier
run: yarn prettier:check
build:
name: Build, lint, and test on Node ${{ matrix.node }} and ${{ matrix.os }}

runs-on: ${{ matrix.os }}
strategy:
matrix:
Expand All @@ -22,12 +37,6 @@ jobs:
- name: Install deps and build (with cache)
uses: bahmutov/npm-install@v1

- name: Lint
run: yarn lint

- name: Prettier
run: yarn prettier:check

- name: Test
run: yarn test --ci --coverage --maxWorkers=2

Expand Down
10 changes: 5 additions & 5 deletions src/Points.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -208,26 +208,26 @@ export function Points({
<instancedMesh
args={[undefined, undefined, data.length]}
ref={meshRef}
onPointerUp={(e) => {
onPointerUp={e => {
if (e.intersections) {
const instanceIds = e.intersections
.map((e) => e?.instanceId)
.map(e => e?.instanceId)
.filter((i): i is NonNullable<typeof i> => i != null);

// Multi click
onPointsClicked &&
onPointsClicked(instanceIds.map((i) => data[i]));
onPointsClicked(instanceIds.map(i => data[i]));

// Single click
instanceIds.length > 0 &&
onPointClicked &&
onPointClicked(data[instanceIds[0]]);
}
}}
onPointerOver={(e) => {
onPointerOver={e => {
if (e.intersections) {
const instanceIds = e.intersections
.map((e) => e?.instanceId)
.map(e => e?.instanceId)
.filter((i): i is NonNullable<typeof i> => i != null);

// Single instance callback
Expand Down

0 comments on commit 05b3e7b

Please sign in to comment.