Dear NocoBase Support Team,
I am currently developing a custom plugin for NocoBase v2.1, but the plugin does not work as expected after installation.
The plugin name is:
@test/plugin-login-custom
The purpose of this plugin is to customize or replace the default authentication/login page in NocoBase.
However, I am facing several issues:
- Custom Login UI Does Not Override Default Login Page
I tried to register my custom login component using:
this.app.addComponents({
AuthLayout: LoginView,
SignInPage: LoginView,
});
I also tried to override the signin route directly:
this.router.add(‘auth.signin’, {
Component: LoginView,
});
The plugin compiles successfully, but the frontend still shows the default login page from:
@nocobase/plugin-auth
There is no error message in the browser console or server logs. The override seems to be ignored silently.
Could you please confirm the official method to override the login page or /signin route in NocoBase v2.1?
- Confusion About client-v2 Plugin Structure
From testing, it seems that NocoBase v2.1 expects frontend files under:
src/client-v2
dist/client-v2/index.js
However, older documentation and some build outputs still refer to:
src/client
dist/client/index.js
Could you please confirm the correct frontend structure for a NocoBase v2.1 plugin?
Should a plugin use client-v2 instead of client?
- Build Failure During Type Declaration Generation
When running the build command, the build fails during .d.ts generation with errors such as:
TS2307: Cannot find module ‘@nocobase/client’
TS2307: Cannot find module ‘@nocobase/client-v2’
It looks like the declaration build process cannot resolve internal NocoBase packages.
Could you please provide a recommended tsconfig.json and build configuration for a standalone NocoBase v2.1 plugin?
- Plugin Upload Package Format
When I upload a normal .zip or .tar.gz file to Plugin Manager, I get this error:
EISDIR: illegal operation on a directory
After testing, it seems that the Plugin Manager only accepts a package generated by:
npm pack
Could you please confirm the official package format required for uploading plugins through Plugin Manager?
Environment:
NocoBase version: v2.1
Plugin type: Custom frontend/backend plugin
Frontend target: client-v2
Goal: Override default login page / authentication UI
Package name: @test/plugin-login-custom
Questions:
Could you please help confirm:
- What is the correct way to override the default login page in NocoBase v2.1?
- Should plugins use client-v2 instead of client?
- What is the correct build configuration for a standalone v2.1 plugin?
- What is the required package format for uploading a plugin to Plugin Manager?
- Is overriding @nocobase/plugin-auth login UI officially supported in v2.1?
A working example or code snippet would be very helpful.
Thank you very much.