mirror of
https://github.com/xtr-dev/payload-feature-flags.git
synced 2025-12-10 02:43:25 +00:00
Replace redundant components with updated feature flag hooks and views. Add comprehensive documentation and ESLint config for improved development workflow.
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
import { withPayload } from '@payloadcms/next/withPayload'
|
||||
import { fileURLToPath } from 'url'
|
||||
|
||||
import path from 'path'
|
||||
import { fileURLToPath } from 'url'
|
||||
|
||||
const dirname = path.dirname(fileURLToPath(import.meta.url))
|
||||
|
||||
@@ -13,6 +14,15 @@ const nextConfig = {
|
||||
'.mjs': ['.mts', '.mjs'],
|
||||
}
|
||||
|
||||
// Add webpack aliases for local plugin development
|
||||
webpackConfig.resolve.alias = {
|
||||
...webpackConfig.resolve.alias,
|
||||
'payload-feature-flags/views': path.resolve(dirname, '../src/exports/views.ts'),
|
||||
'payload-feature-flags/client': path.resolve(dirname, '../src/exports/client.ts'),
|
||||
'payload-feature-flags/rsc': path.resolve(dirname, '../src/exports/rsc.ts'),
|
||||
'payload-feature-flags': path.resolve(dirname, '../src/index.ts'),
|
||||
}
|
||||
|
||||
return webpackConfig
|
||||
},
|
||||
serverExternalPackages: ['mongodb-memory-server'],
|
||||
|
||||
Reference in New Issue
Block a user