Skip to content

Commit a5c1195

Browse files
committed
use publishConfig for each package instead of aliasing in the examples
1 parent c9fda0d commit a5c1195

File tree

32 files changed

+32
-194
lines changed

32 files changed

+32
-194
lines changed
Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,11 @@
11
import { defineConfig } from 'vite'
2-
import path from 'path'
32
import react from '@vitejs/plugin-react'
43
import basicSsl from '@vitejs/plugin-basic-ssl'
54

65
// https://vitejs.dev/config/
76
export default defineConfig({
87
plugins: [react(), basicSsl()],
98
resolve: {
10-
alias: [
11-
{ find: '@react-three/xr', replacement: path.resolve(__dirname, '../../packages/react/xr/src/index.ts') },
12-
{
13-
find: '@pmndrs/pointer-events',
14-
replacement: path.resolve(__dirname, '../../packages/pointer-events/src/index.ts'),
15-
},
16-
],
179
dedupe: ['@react-three/fiber', 'three'],
1810
},
1911
})

examples/editor/vite.config.ts

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
import { defineConfig } from 'vite'
2-
import path from 'path'
32
import react from '@vitejs/plugin-react'
43
import basicSsl from '@vitejs/plugin-basic-ssl'
54

@@ -8,13 +7,6 @@ export default defineConfig({
87
plugins: [react(), basicSsl()],
98
base: '/xr/examples/editor/',
109
resolve: {
11-
alias: [
12-
{ find: '@react-three/xr', replacement: path.resolve(__dirname, '../../packages/react/xr/src/index.ts') },
13-
{
14-
find: '@pmndrs/pointer-events',
15-
replacement: path.resolve(__dirname, '../../packages/pointer-events/src/index.ts'),
16-
},
17-
],
1810
dedupe: ['@react-three/fiber', 'three'],
1911
},
2012
})

examples/handheld-ar/vite.config.ts

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,11 @@
11
import { defineConfig } from 'vite'
2-
import path from 'path'
32
import react from '@vitejs/plugin-react'
43
import basicSsl from '@vitejs/plugin-basic-ssl'
54

65
// https://vitejs.dev/config/
76
export default defineConfig({
87
plugins: [react(), basicSsl()],
98
resolve: {
10-
alias: [
11-
{ find: '@react-three/xr', replacement: path.resolve(__dirname, '../../packages/react/xr/src/index.ts') },
12-
{
13-
find: '@pmndrs/pointer-events',
14-
replacement: path.resolve(__dirname, '../../packages/pointer-events/src/index.ts'),
15-
},
16-
],
179
dedupe: ['@react-three/fiber', 'three'],
1810
},
1911
})
Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
import path from 'path'
21
import { defineConfig } from 'vite'
32
import basicSsl from '@vitejs/plugin-basic-ssl'
43

@@ -10,12 +9,6 @@ export default defineConfig({
109
},
1110
base: '/handle-vanilla/',
1211
resolve: {
13-
alias: [
14-
{
15-
find: '@pmndrs/pointer-events',
16-
replacement: path.resolve(__dirname, '../../packages/pointer-events/src/index.ts'),
17-
},
18-
],
1912
dedupe: ['three'],
2013
},
2114
})

examples/handle/vite.config.ts

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,11 @@
11
import { defineConfig } from 'vite'
2-
import path from 'path'
32
import react from '@vitejs/plugin-react'
43
import basicSsl from '@vitejs/plugin-basic-ssl'
54

65
// https://vitejs.dev/config/
76
export default defineConfig({
87
plugins: [react(), basicSsl()],
98
resolve: {
10-
alias: [
11-
{ find: '@react-three/xr', replacement: path.resolve(__dirname, '../../packages/react/xr/src/index.ts') },
12-
{
13-
find: '@pmndrs/pointer-events',
14-
replacement: path.resolve(__dirname, '../../packages/pointer-events/src/index.ts'),
15-
},
16-
],
179
dedupe: ['@react-three/fiber', 'three'],
1810
},
1911
})

examples/hit-testing/vite.config.ts

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
import { defineConfig } from 'vite'
2-
import path from 'path'
32
import react from '@vitejs/plugin-react'
43
import basicSsl from '@vitejs/plugin-basic-ssl'
54

@@ -8,13 +7,6 @@ export default defineConfig({
87
plugins: [react(), basicSsl()],
98
base: '/xr/examples/hit-testing/',
109
resolve: {
11-
alias: [
12-
{ find: '@react-three/xr', replacement: path.resolve(__dirname, '../../packages/react/xr/src/index.ts') },
13-
{
14-
find: '@pmndrs/pointer-events',
15-
replacement: path.resolve(__dirname, '../../packages/pointer-events/src/index.ts'),
16-
},
17-
],
1810
dedupe: ['@react-three/fiber', 'three'],
1911
},
2012
})

examples/layers/vite.config.ts

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
import { defineConfig } from 'vite'
2-
import path from 'path'
32
import react from '@vitejs/plugin-react'
43
import basicSsl from '@vitejs/plugin-basic-ssl'
54

@@ -8,13 +7,6 @@ export default defineConfig({
87
plugins: [react(), basicSsl()],
98
base: '/xr/examples/layers/',
109
resolve: {
11-
alias: [
12-
{ find: '@react-three/xr', replacement: path.resolve(__dirname, '../../packages/react/xr/src/index.ts') },
13-
{
14-
find: '@pmndrs/pointer-events',
15-
replacement: path.resolve(__dirname, '../../packages/pointer-events/src/index.ts'),
16-
},
17-
],
1810
dedupe: ['@react-three/fiber', 'three'],
1911
},
2012
})

examples/minecraft/vite.config.ts

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
import { defineConfig } from 'vite'
2-
import path from 'path'
32
import react from '@vitejs/plugin-react'
43
import basicSsl from '@vitejs/plugin-basic-ssl'
54

@@ -8,13 +7,6 @@ export default defineConfig({
87
plugins: [react(), basicSsl()],
98
base: '/xr/examples/minecraft/',
109
resolve: {
11-
alias: [
12-
{ find: '@react-three/xr', replacement: path.resolve(__dirname, '../../packages/react/xr/src/index.ts') },
13-
{
14-
find: '@pmndrs/pointer-events',
15-
replacement: path.resolve(__dirname, '../../packages/pointer-events/src/index.ts'),
16-
},
17-
],
1810
dedupe: ['@react-three/fiber', 'three'],
1911
},
2012
})

examples/miniature/vite.config.ts

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,11 @@
11
import { defineConfig } from 'vite'
2-
import path from 'path'
32
import react from '@vitejs/plugin-react'
43
import basicSsl from '@vitejs/plugin-basic-ssl'
54

65
// https://vitejs.dev/config/
76
export default defineConfig({
87
plugins: [react(), basicSsl()],
98
resolve: {
10-
alias: [
11-
{ find: '@react-three/xr', replacement: path.resolve(__dirname, '../../packages/react/xr/src/index.ts') },
12-
{
13-
find: '@pmndrs/pointer-events',
14-
replacement: path.resolve(__dirname, '../../packages/pointer-events/src/index.ts'),
15-
},
16-
],
179
dedupe: ['@react-three/fiber', 'three'],
1810
},
1911
})

examples/pingpong/vite.config.ts

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
import { defineConfig } from 'vite'
2-
import path from 'path'
32
import react from '@vitejs/plugin-react'
43
import basicSsl from '@vitejs/plugin-basic-ssl'
54

@@ -8,13 +7,6 @@ export default defineConfig({
87
plugins: [react(), basicSsl()],
98
base: '/xr/examples/pingpong/',
109
resolve: {
11-
alias: [
12-
{ find: '@react-three/xr', replacement: path.resolve(__dirname, '../../packages/react/xr/src/index.ts') },
13-
{
14-
find: '@pmndrs/pointer-events',
15-
replacement: path.resolve(__dirname, '../../packages/pointer-events/src/index.ts'),
16-
},
17-
],
1810
dedupe: ['@react-three/fiber', 'three'],
1911
},
2012
})

0 commit comments

Comments
 (0)