ui-plugin.ts 903 B

12345678910111213141516171819202122232425262728
  1. import { AdminUiExtension } from '@vendure/common/lib/shared-types';
  2. import { VendurePlugin } from '@vendure/core';
  3. import path from 'path';
  4. @VendurePlugin({})
  5. export class UiPlugin {
  6. static uiExtensions: AdminUiExtension[] = [
  7. {
  8. extensionPath: path.join(__dirname, 'extensions'),
  9. ngModules: [
  10. {
  11. type: 'lazy',
  12. ngModuleFileName: 'ui-plugin.module.ts',
  13. ngModuleName: 'TestModule',
  14. },
  15. {
  16. type: 'shared',
  17. ngModuleFileName: 'ui-shared-plugin.module.ts',
  18. ngModuleName: 'TestSharedModule',
  19. },
  20. ],
  21. staticAssets: [
  22. path.join(__dirname, 'extensions/js-app'),
  23. path.join(__dirname, 'extensions/vue-app'),
  24. ],
  25. },
  26. ];
  27. }