-
Notifications
You must be signed in to change notification settings - Fork 0
feat: Create new queue plugin based off pg-boss #629
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: Create new queue plugin based off pg-boss #629
Conversation
|
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
🦋 Changeset detectedLatest commit: 58d9f35 The changes in this PR will be included in the next version bump. This PR includes changesets to release 18 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
WalkthroughThis change introduces a new modular, provider-based queue plugin for Baseplate projects, implemented with a pg-boss backend for PostgreSQL-based background job processing. It adds code generation templates, TypeScript types, Fastify integration, React-based configuration UIs, and registry patterns for queue management. Supporting scripts, configuration, and documentation are included. Changes
Sequence Diagram(s)sequenceDiagram
participant User
participant ReactConfigUI
participant ProjectBuilder
participant QueuePlugin
participant PgBossPlugin
participant PgBossService
participant FastifyApp
participant WorkerScript
User->>ReactConfigUI: Configure queue plugin and select implementation
ReactConfigUI->>ProjectBuilder: Save queue config (provider, options)
ProjectBuilder->>QueuePlugin: Register queue config and provider
QueuePlugin->>PgBossPlugin: Initialize backend with config
PgBossPlugin->>PgBossService: Setup pg-boss, register queues
FastifyApp->>PgBossPlugin: Register plugin on startup
WorkerScript->>PgBossService: Start all queue workers
PgBossService->>PgBoss: Process jobs, handle retries, schedule, shutdown
User->>ReactConfigUI: Monitor/edit queue/job status
Estimated code review effort🎯 4 (Complex) | ⏱️ ~45 minutes Possibly related PRs
Note ⚡️ Unit Test Generation is now available in beta!Learn more here, or try it out under "Finishing Touches" below. 📜 Recent review detailsConfiguration used: .coderabbit.yaml 📒 Files selected for processing (2)
✅ Files skipped from review due to trivial changes (1)
🚧 Files skipped from review as they are similar to previous changes (1)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
✨ Finishing Touches🧪 Generate unit tests
🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
SupportNeed help? Create a ticket on our support page for assistance with any issues or questions. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
Documentation and Community
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 7
🧹 Nitpick comments (6)
plugins/plugin-queue/.gitignore (1)
64-82: Duplicate.cachepatterns – safe but noisy
.cacheis ignored twice (Lines 64–66 and Lines 78–81).
While harmless, removing the duplicate keeps the ignore list tidy and avoids future merge noise.Also applies to: 78-82
tsconfig.build.json (1)
38-42: Keepreferencesarray alphabetically orderedFor quicker look-ups and to minimise merge conflicts, keep the
referenceslist sorted.
plugin-queueshould come beforeplugin-storage.- { - "path": "./plugins/plugin-storage/tsconfig.build.json" - }, - { - "path": "./plugins/plugin-queue/tsconfig.build.json" - } + { + "path": "./plugins/plugin-queue/tsconfig.build.json" + }, + { + "path": "./plugins/plugin-storage/tsconfig.build.json" + }plugins/plugin-queue/tsconfig.node.json (1)
1-9: Prefer extending the repo’s base tsconfig to avoid option drift
If the monorepo already has a sharedtsconfig.node.json, consider inheriting from it and overriding only what’s unique:-{ - "compilerOptions": { - "composite": true, - "moduleResolution": "bundler", - "module": "ES2022", - "strict": true - }, - "include": ["vite.config.ts"] -} +{ + "extends": "../../tsconfig.node.json", + "compilerOptions": { + "composite": true + }, + "include": ["vite.config.ts"] +}Keeps compiler options consistent across packages and reduces maintenance.
plugins/plugin-queue/index.html (1)
17-17: Consider using a more descriptive title.The generic title "React Remote" doesn't clearly indicate this is for the queue plugin. Consider using something more descriptive like "Queue Plugin Configuration" or "Baseplate Queue Plugin".
- <title>React Remote</title> + <title>Queue Plugin Configuration</title>plugins/plugin-queue/README.md (1)
27-27: Add missing newline at end of file.Line 27 is missing a proper newline termination, which is a common convention for text files.
-This package is part of the Baseplate monorepo and extends Baseplate projects with comprehensive background job processing functionality. +This package is part of the Baseplate monorepo and extends Baseplate projects with comprehensive background job processing functionality. +plugins/plugin-queue/src/pg-boss/core/generators/pg-boss/templates/src/services/pg-boss.service.ts (1)
259-259: Consider preserving type information in pg-boss operations.The type casting to
objecton lines 259 and 272 might lose valuable type information. For the error on line 272, consider preserving the error stack:- await boss.complete(this.name, job.id, result as object); + await boss.complete(this.name, job.id, result as object ?? undefined);- await boss.fail(this.name, job.id, { err: String(error) }); + await boss.fail(this.name, job.id, { + err: error instanceof Error ? error.message : String(error), + stack: error instanceof Error ? error.stack : undefined + });Also applies to: 272-272
| - * | ||
| - 6. Disclaimer of Warranty \* | ||
| - ------------------------- \* | ||
| - * | ||
| - Covered Software is provided under this License on an "as is" \* | ||
| - basis, without warranty of any kind, either expressed, implied, or \* | ||
| - statutory, including, without limitation, warranties that the \* | ||
| - Covered Software is free of defects, merchantable, fit for a \* | ||
| - particular purpose or non-infringing. The entire risk as to the \* | ||
| - quality and performance of the Covered Software is with You. \* | ||
| - Should any Covered Software prove defective in any respect, You \* | ||
| - (not any Contributor) assume the cost of any necessary servicing, \* | ||
| - repair, or correction. This disclaimer of warranty constitutes an \* | ||
| - essential part of this License. No use of any Covered Software is \* | ||
| - authorized under this License except under this disclaimer. \* | ||
| - * | ||
|
|
||
| --- | ||
|
|
||
| --- | ||
|
|
||
| - * | ||
| - 7. Limitation of Liability \* | ||
| - -------------------------- \* | ||
| - * | ||
| - Under no circumstances and under no legal theory, whether tort \* | ||
| - (including negligence), contract, or otherwise, shall any \* | ||
| - Contributor, or anyone who distributes Covered Software as \* | ||
| - permitted above, be liable to You for any direct, indirect, \* | ||
| - special, incidental, or consequential damages of any character \* | ||
| - including, without limitation, damages for lost profits, loss of \* | ||
| - goodwill, work stoppage, computer failure or malfunction, or any \* | ||
| - and all other commercial damages or losses, even if such party \* | ||
| - shall have been informed of the possibility of such damages. This \* | ||
| - limitation of liability shall not apply to liability for death or \* | ||
| - personal injury resulting from such party's negligence to the \* | ||
| - extent applicable law prohibits such limitation. Some \* | ||
| - jurisdictions do not allow the exclusion or limitation of \* | ||
| - incidental or consequential damages, so this exclusion and \* | ||
| - limitation may not apply to You. \* | ||
| - * | ||
|
|
||
| --- | ||
|
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fix formatting issues in disclaimer and limitation sections.
Sections 6 and 7 have unusual formatting with asterisks and dashes that don't match the rest of the document. These sections should follow the standard MPL-2.0 format:
----
-
-- *
-- 6. Disclaimer of Warranty \*
-- ------------------------- \*
-- *
-- Covered Software is provided under this License on an "as is" \*
-- basis, without warranty of any kind, either expressed, implied, or \*
-- statutory, including, without limitation, warranties that the \*
-- Covered Software is free of defects, merchantable, fit for a \*
-- particular purpose or non-infringing. The entire risk as to the \*
-- quality and performance of the Covered Software is with You. \*
-- Should any Covered Software prove defective in any respect, You \*
-- (not any Contributor) assume the cost of any necessary servicing, \*
-- repair, or correction. This disclaimer of warranty constitutes an \*
-- essential part of this License. No use of any Covered Software is \*
-- authorized under this License except under this disclaimer. \*
-- *
-
----
+6. Disclaimer of Warranty
+
+---
+
+Covered Software is provided under this License on an "as is"
+basis, without warranty of any kind, either expressed, implied, or
+statutory, including, without limitation, warranties that the
+Covered Software is free of defects, merchantable, fit for a
+particular purpose or non-infringing. The entire risk as to the
+quality and performance of the Covered Software is with You.
+Should any Covered Software prove defective in any respect, You
+(not any Contributor) assume the cost of any necessary servicing,
+repair, or correction. This disclaimer of warranty constitutes an
+essential part of this License. No use of any Covered Software is
+authorized under this License except under this disclaimer.Apply similar formatting fixes to Section 7 (Limitation of Liability).
Committable suggestion skipped: line range outside the PR's diff.
🤖 Prompt for AI Agents
In plugins/plugin-queue/LICENSE between lines 275 and 318, sections 6 and 7 have
inconsistent formatting with asterisks and dashes that deviate from the standard
MPL-2.0 license style. Remove the extra asterisks and dashes, and reformat these
sections to match the typical MPL-2.0 layout, ensuring clean, plain text
paragraphs with proper headings and spacing consistent with the rest of the
license document.
| @@ -0,0 +1 @@ | |||
| export { default } from '@baseplate-dev/tools/prettier-react'; | |||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
💡 Verification agent
🧩 Analysis chain
Verify dependency placement for @baseplate-dev/tools.
Static analysis indicates that @baseplate-dev/tools should be listed in dependencies rather than devDependencies since this file re-exports from it at runtime.
🏁 Script executed:
#!/bin/bash
# Check if @baseplate-dev/tools is correctly placed in package.json dependencies
echo "Checking dependency placement in package.json:"
cat plugins/plugin-queue/package.json | jq '{dependencies, devDependencies}' | grep -A 10 -B 10 "baseplate-dev/tools"
# Check other plugins for consistency
echo -e "\nChecking other plugin prettier configs for comparison:"
find plugins/ -name "prettier.config.js" -exec echo "=== {} ===" \; -exec cat {} \;Length of output: 1455
Move @baseplate-dev/tools into dependencies
The shared Prettier config is loaded at runtime by Prettier, so @baseplate-dev/tools must be a runtime dependency, not a dev-only one. Update plugins/plugin-queue/package.json (and likewise in plugin-auth/plugin-storage) as follows:
--- a/plugins/plugin-queue/package.json
+++ b/plugins/plugin-queue/package.json
@@
"dependencies": {
+ "@baseplate-dev/tools": "workspace:*",
/* other deps… */
},
"devDependencies": {
- "@baseplate-dev/tools": "workspace:*",
/* other devDeps… */
}📝 Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.
| export { default } from '@baseplate-dev/tools/prettier-react'; | |
| // plugins/plugin-queue/package.json | |
| { | |
| "dependencies": { | |
| "@baseplate-dev/tools": "workspace:*", | |
| /* other deps… */ | |
| }, | |
| "devDependencies": { | |
| /* other devDeps… */ | |
| } | |
| } |
🧰 Tools
🪛 ESLint
[error] 1-1: '@baseplate-dev/tools' should be listed in the project's dependencies, not devDependencies.
(import-x/no-extraneous-dependencies)
🤖 Prompt for AI Agents
In plugins/plugin-queue/prettier.config.js at line 1, the package
'@baseplate-dev/tools' is imported but currently listed only as a devDependency
in package.json. To fix this, move '@baseplate-dev/tools' from devDependencies
to dependencies in plugins/plugin-queue/package.json and also update plugin-auth
and plugin-storage package.json files similarly to ensure it is available at
runtime when Prettier loads the config.
| import { | ||
| cleanupOrphanedSchedules, | ||
| initializePgBoss, | ||
| shutdownPgBoss, | ||
| } from '$pgBossService'; | ||
| import { logError } from '%errorHandlerServiceImports'; | ||
| import { logger } from '%loggerServiceImports'; | ||
| import { QUEUE_REGISTRY } from '%queuesImports'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🛠️ Refactor suggestion
Fix import ordering to comply with ESLint rules.
The imports should be sorted with external dependencies first, then local imports.
import {
cleanupOrphanedSchedules,
initializePgBoss,
shutdownPgBoss,
} from '$pgBossService';
-import { logError } from '%errorHandlerServiceImports';
-import { logger } from '%loggerServiceImports';
-import { QUEUE_REGISTRY } from '%queuesImports';
+import { logError } from '%errorHandlerServiceImports';
+import { logger } from '%loggerServiceImports';
+import { QUEUE_REGISTRY } from '%queuesImports';Committable suggestion skipped: line range outside the PR's diff.
🧰 Tools
🪛 ESLint
[error] 9-9: Expected "%errorHandlerServiceImports" to come before "$pgBossService".
(perfectionist/sort-imports)
🤖 Prompt for AI Agents
In
plugins/plugin-queue/src/pg-boss/core/generators/pg-boss/templates/src/scripts/run-workers.ts
between lines 4 and 11, the import statements are not ordered according to
ESLint rules. Reorder the imports so that external dependencies come first,
followed by local imports. This means placing imports from external packages or
modules before imports from local paths or aliases.
| main().catch((error: unknown) => { | ||
| logError(error, { source: 'run-workers' }); | ||
| process.exit(1); | ||
| }); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🛠️ Refactor suggestion
Use top-level await instead of promise chain.
Modern Node.js supports top-level await, which is cleaner than promise chains.
-// Start the worker process
-main().catch((error: unknown) => {
- logError(error, { source: 'run-workers' });
- process.exit(1);
-});
+// Start the worker process
+try {
+ await main();
+} catch (error: unknown) {
+ logError(error, { source: 'run-workers' });
+ process.exit(1);
+}📝 Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.
| main().catch((error: unknown) => { | |
| logError(error, { source: 'run-workers' }); | |
| process.exit(1); | |
| }); | |
| // Start the worker process | |
| try { | |
| await main(); | |
| } catch (error: unknown) { | |
| logError(error, { source: 'run-workers' }); | |
| process.exit(1); | |
| } |
🧰 Tools
🪛 ESLint
[error] 104-104: Prefer top-level await over using a promise chain.
(unicorn/prefer-top-level-await)
🤖 Prompt for AI Agents
In
plugins/plugin-queue/src/pg-boss/core/generators/pg-boss/templates/src/scripts/run-workers.ts
around lines 104 to 107, replace the main().catch promise chain with top-level
await syntax. Remove the .catch block and instead use a try-catch block around
the top-level await call to main(), logging errors and exiting the process
inside the catch block for cleaner and more modern asynchronous handling.
| @@ -0,0 +1 @@ | |||
| export type * from './core/index.js'; | |||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Syntax error – export type * is invalid TypeScript
export type * from './core/index.js'; does not compile.
Type-only re-exports must use named bindings:
-export type * from './core/index.js';
+export * from './core/index.js'; // re-export everything (types & values)
+// or, if you truly need a type-only re-export:
+// export type { SomeType, OtherType } from './core/index.js';This will currently break the build under tsc --strict.
📝 Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.
| export type * from './core/index.js'; | |
| export * from './core/index.js'; // re-export everything (types & values) | |
| // or, if you truly need a type-only re-export: | |
| // export type { SomeType, OtherType } from './core/index.js'; |
🤖 Prompt for AI Agents
In plugins/plugin-queue/src/pg-boss/index.ts at line 1, the statement `export
type * from './core/index.js';` is invalid TypeScript syntax for type-only
exports. Replace this with named type exports by explicitly listing the types to
export from './core/index.js' using `export type { TypeName1, TypeName2 } from
'./core/index.js';` to fix the syntax error and ensure the build passes under
`tsc --strict`.
| @import 'tailwindcss/theme.css' layer(theme) prefix(queue); | ||
| @import 'tailwindcss/utilities.css' layer(utilities) prefix(queue); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Invalid @import … prefix() syntax – will fail CSS parsing
prefix(queue) is not a valid parameter in the CSS @import rule (see Biome parse errors).
Tailwind class prefixing is configured in tailwind.config.{js,cjs} via the prefix option, not at import-time.
-@import 'tailwindcss/theme.css' layer(theme) prefix(queue);
-@import 'tailwindcss/utilities.css' layer(utilities) prefix(queue);
+@import 'tailwindcss/theme.css' layer(theme);
+@import 'tailwindcss/utilities.css' layer(utilities);Add prefix: 'queue-' (or similar) in the plugin’s Tailwind config to satisfy the style-isolation guideline.
🧰 Tools
🪛 Biome (2.1.2)
[error] 3-3: expected , but instead found (
Remove (
(parse)
[error] 4-4: expected , but instead found (
Remove (
(parse)
[error] 3-3: Don't use unknown media feature names.
Unexpected unknown media feature name.
You should use media feature names defined in the CSS Specifications.
(lint/correctness/noUnknownMediaFeatureName)
[error] 4-4: Don't use unknown media feature names.
Unexpected unknown media feature name.
You should use media feature names defined in the CSS Specifications.
(lint/correctness/noUnknownMediaFeatureName)
🤖 Prompt for AI Agents
In plugins/plugin-queue/src/styles.css at lines 3 to 4, the use of prefix(queue)
in the @import statements is invalid CSS syntax and causes parsing errors.
Remove the prefix(queue) from both @import lines. Instead, configure the
Tailwind class prefix by adding a prefix option like prefix: 'queue-' in the
plugin's tailwind.config.js or tailwind.config.cjs file to properly isolate
styles.
| getModuleFederationTargets, | ||
| rewriteDistToSrc, | ||
| } from '@baseplate-dev/project-builder-lib/plugin-tools'; | ||
| import { srcSubpathImportPlugin } from '@baseplate-dev/tools/src-subpath-import-plugin'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fix dependency classification for @baseplate-dev/tools.
The static analysis correctly identifies that @baseplate-dev/tools should be listed in dependencies rather than devDependencies since it's imported in production code.
Move @baseplate-dev/tools from devDependencies to dependencies in the package.json file.
🧰 Tools
🪛 ESLint
[error] 7-7: '@baseplate-dev/tools' should be listed in the project's dependencies, not devDependencies.
(import-x/no-extraneous-dependencies)
🤖 Prompt for AI Agents
In plugins/plugin-queue/vite.config.ts at line 7, the import from
'@baseplate-dev/tools' is used in production code, so update the package.json by
moving '@baseplate-dev/tools' from devDependencies to dependencies to correctly
classify it as a runtime dependency.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 0
♻️ Duplicate comments (1)
plugins/plugin-queue/vite.config.ts (1)
7-7: Fix dependency classification for @baseplate-dev/tools.The static analysis correctly identifies that
@baseplate-dev/toolsshould be listed in dependencies rather than devDependencies since it's imported in production code.
🧹 Nitpick comments (1)
plugins/plugin-queue/vite.config.ts (1)
14-14: Use consistent directory reference.Line 14 uses
__dirnamewhile line 30 usesimport.meta.dirname. For consistency and modern Node.js practices, useimport.meta.dirnamethroughout the file.- const viteTargets = await getModuleFederationTargets(__dirname, { + const viteTargets = await getModuleFederationTargets(import.meta.dirname, {
📜 Review details
Configuration used: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
⛔ Files ignored due to path filters (1)
pnpm-lock.yamlis excluded by!**/pnpm-lock.yaml
📒 Files selected for processing (1)
plugins/plugin-queue/vite.config.ts(1 hunks)
🧰 Additional context used
📓 Path-based instructions (4)
**/*.{ts,tsx}
📄 CodeRabbit Inference Engine (CLAUDE.md)
**/*.{ts,tsx}: Import UI components from the@baseplate-dev/ui-componentspackage as shown in the provided examples.
Use both standalone and React Hook Form controller variants for form components from@baseplate-dev/ui-componentsas appropriate.
If a particular interface or type is not exported, change the file so it is exported.
**/*.{ts,tsx}: TypeScript with strict type checking
Always include return types on top-level functions including React components (React.ReactElement)
Include absolute paths in import statements via tsconfig paths (@src/is the alias forsrc/)
If a particular interface or type is not exported, change the file so it is exported
Files:
plugins/plugin-queue/vite.config.ts
**/*.{js,ts,tsx}
📄 CodeRabbit Inference Engine (.cursor/rules/code-style.mdc)
Node 16 module resolution - include file extensions in imports (
.js)
Files:
plugins/plugin-queue/vite.config.ts
**/*.{ts,tsx,js}
📄 CodeRabbit Inference Engine (.cursor/rules/code-style.mdc)
**/*.{ts,tsx,js}: Sort imports by group: external libs first, then local imports
Use camelCase for variables/functions, PascalCase for types/classes
Order functions such that functions are placed below the variables/functions they use
We use the prefer using nullish coalescing operator (??) ESLint rule instead of a logical or (||), as it is a safer operator
Use console.info/warn/error instead of console.log
Files:
plugins/plugin-queue/vite.config.ts
**/*
📄 CodeRabbit Inference Engine (.cursor/rules/code-style.mdc)
Use kebab-case for file names
Files:
plugins/plugin-queue/vite.config.ts
🧠 Learnings (8)
📚 Learning: applies to {packages/project-builder-web/**,packages/ui-components/**}/*.tsx : use shadcn-based comp...
Learnt from: CR
PR: halfdomelabs/baseplate#0
File: .cursor/rules/ui-rules.mdc:0-0
Timestamp: 2025-07-22T09:11:29.223Z
Learning: Applies to {packages/project-builder-web/**,packages/ui-components/**}/*.tsx : Use ShadCN-based components from `baseplate-dev/ui-components` and always prefer these components over creating custom ones
Applied to files:
plugins/plugin-queue/vite.config.ts
📚 Learning: applies to {packages/project-builder-web/**,packages/ui-components/**}/*.tsx : in plugins, prefix al...
Learnt from: CR
PR: halfdomelabs/baseplate#0
File: .cursor/rules/ui-rules.mdc:0-0
Timestamp: 2025-07-22T09:11:29.223Z
Learning: Applies to {packages/project-builder-web/**,packages/ui-components/**}/*.tsx : In plugins, prefix all Tailwind classes with the plugin name (e.g., `auth-`, `storage-`)
Applied to files:
plugins/plugin-queue/vite.config.ts
📚 Learning: run `pnpm lint:affected` and `pnpm typecheck` before committing changes....
Learnt from: CR
PR: halfdomelabs/baseplate#0
File: CLAUDE.md:0-0
Timestamp: 2025-07-22T09:09:23.016Z
Learning: Run `pnpm lint:affected` and `pnpm typecheck` before committing changes.
Applied to files:
plugins/plugin-queue/vite.config.ts
📚 Learning: ignore eslint import ordering rules for files in templates/** directories as these are code generati...
Learnt from: kingston
PR: halfdomelabs/baseplate#623
File: plugins/plugin-auth/src/local-auth/core/generators/react-session/templates/src/app/user-session-provider.tsx:6-12
Timestamp: 2025-07-30T13:27:20.000Z
Learning: Ignore ESLint import ordering rules for files in templates/** directories as these are code generation templates, not direct source code.
Applied to files:
plugins/plugin-queue/vite.config.ts
📚 Learning: applies to **/*.{ts,tsx} : import ui components from the `@baseplate-dev/ui-components` package as s...
Learnt from: CR
PR: halfdomelabs/baseplate#0
File: CLAUDE.md:0-0
Timestamp: 2025-07-22T09:09:23.016Z
Learning: Applies to **/*.{ts,tsx} : Import UI components from the `baseplate-dev/ui-components` package as shown in the provided examples.
Applied to files:
plugins/plugin-queue/vite.config.ts
📚 Learning: applies to **/*.{ts,tsx} : if a particular interface or type is not exported, change the file so it ...
Learnt from: CR
PR: halfdomelabs/baseplate#0
File: CLAUDE.md:0-0
Timestamp: 2025-07-22T09:09:23.016Z
Learning: Applies to **/*.{ts,tsx} : If a particular interface or type is not exported, change the file so it is exported.
Applied to files:
plugins/plugin-queue/vite.config.ts
📚 Learning: avoid importing directly from 'dist' directories. instead, expose functionality through the package'...
Learnt from: kingston
PR: halfdomelabs/baseplate#428
File: packages/project-builder-server/src/sync/index.ts:5-5
Timestamp: 2025-01-23T09:12:46.178Z
Learning: Avoid importing directly from 'dist' directories. Instead, expose functionality through the package's public API and import from the main package entry point.
Applied to files:
plugins/plugin-queue/vite.config.ts
📚 Learning: in react projects using vite, keep the .env file naming convention as .env.development, .env.product...
Learnt from: kingston
PR: halfdomelabs/baseplate#598
File: packages/fastify-generators/src/generators/yoga/yoga-plugin/templates/src/plugins/graphql/index.ts:18-18
Timestamp: 2025-07-10T06:49:07.714Z
Learning: In React projects using Vite, keep the .env file naming convention as .env.development, .env.production, etc. even when internal application environment values use shorter abbreviations like 'dev', 'stage', 'prod'. This follows Vite's mode conventions.
Applied to files:
plugins/plugin-queue/vite.config.ts
🧬 Code Graph Analysis (1)
plugins/plugin-queue/vite.config.ts (2)
packages/project-builder-lib/src/plugin-tools/plugin-loader.ts (2)
getModuleFederationTargets(352-410)rewriteDistToSrc(340-342)packages/tools/src-subpath-import-plugin.js (1)
srcSubpathImportPlugin(26-68)
🪛 ESLint
plugins/plugin-queue/vite.config.ts
[error] 7-7: '@baseplate-dev/tools' should be listed in the project's dependencies, not devDependencies.
(import-x/no-extraneous-dependencies)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (3)
- GitHub Check: Lint
- GitHub Check: Test E2E
- GitHub Check: test
🔇 Additional comments (2)
plugins/plugin-queue/vite.config.ts (2)
17-28: LGTM! Well-configured build options for plugin development.The build configuration is well-suited for plugin development with appropriate settings for debugging (sourcemap), development builds (minify: false), and external dependency handling.
29-51: LGTM! Plugins configuration follows best practices.The plugin configuration is well-structured:
- Proper use of
srcSubpathImportPluginfor internal path resolution- Correct module federation setup with appropriate shared dependencies
- Standard React and Tailwind CSS plugin integration
Summary by CodeRabbit
New Features
Enhancements
Documentation
Style & Configuration
Chores