feat: Add new emoji assets and an UpdateBanner component.
Some checks failed
Build and Release / build-and-release (push) Failing after 3m28s
Some checks failed
Build and Release / build-and-release (push) Failing after 3m28s
This commit is contained in:
24
packages/shared/vite.config.js
Normal file
24
packages/shared/vite.config.js
Normal file
@@ -0,0 +1,24 @@
|
||||
import react from '@vitejs/plugin-react';
|
||||
import path from 'path';
|
||||
|
||||
/**
|
||||
* Returns a base Vite config for apps that consume the shared package.
|
||||
* Apps can spread this into their own defineConfig and override as needed.
|
||||
*/
|
||||
export function createSharedConfig({ root, envDir, base = '/', outDir = 'dist' } = {}) {
|
||||
return {
|
||||
plugins: [react()],
|
||||
base,
|
||||
envDir,
|
||||
resolve: {
|
||||
dedupe: ['react', 'react-dom'],
|
||||
alias: {
|
||||
'@shared': path.resolve(root || process.cwd(), 'node_modules/@discord-clone/shared/src'),
|
||||
},
|
||||
},
|
||||
build: {
|
||||
outDir,
|
||||
chunkSizeWarningLimit: 1000,
|
||||
},
|
||||
};
|
||||
}
|
||||
Reference in New Issue
Block a user