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:
2025-09-12 15:35:44 +02:00
parent 453b9eac7c
commit 81780ab7a9
27 changed files with 13326 additions and 260 deletions

View File

@@ -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'],