Scene Config

The configuration parameters of the project frontend are as follows:

  1. 1export default {
  2. 2 base: {
  3. 3 jwt: false,
  4. 4 locale: 'en-us',
  5. 5 disabledModules: [
  6. 6 // 'test-party',
  7. 7 ],
  8. 8 },
  9. 9 api: {
  10. 10 // baseURL: 'http://127.0.0.1:7102',
  11. 11 },
  12. 12 locales: {
  13. 13 'en-us': 'English',
  14. 14 'zh-cn': 'Chinese',
  15. 15 },
  16. 16 layout: {
  17. 17 breakpoint: 600,
  18. 18 items: {
  19. 19 mobile: {
  20. 20 module: 'a-layoutmobile',
  21. 21 component: 'layout',
  22. 22 },
  23. 23 pc: {
  24. 24 module: 'a-layoutpc',
  25. 25 component: 'layout',
  26. 26 },
  27. 27 },
  28. 28 notification: {
  29. 29 closeTimeout: -1,
  30. 30 },
  31. 31 },
  32. 32 markdown: {
  33. 33 style: {
  34. 34 module: 'a-markdownstyle',
  35. 35 },
  36. 36 },
  37. 37 theme: {
  38. 38 type: 'builtIn',
  39. 39 builtIn: {
  40. 40 layout: 'light',
  41. 41 bars: 'empty',
  42. 42 color: 'blue',
  43. 43 customColor: null,
  44. 44 },
  45. 45 thirdParty: null,
  46. 46 },
  47. 47 modules: {
  48. 48 ...
  49. 49 },
  50. 50};

base

Name Description
jwt Whether to enable jwt. If the frontend host environment does not support cookies, you can use the jwt mechanism, such as Mobile App. The system has built-in cookie and jwt mechanisms, you only need to set jwt: true
locale The system will automatically determine the current appropriate language. If no appropriate language is automatically detected, the default configuration here will be used
disabledModules Disabled modules
disabledSuites Disabled suites

api

Name Description
baseURL If the frontend and backend are under the same domain name, the frontend can automatically determine the backend API base url. Otherwise, you need to explicitly specify the backend API base url through this parameter

locales

List of languages supported by the system

layout

Frontend layout parameters:

Name Description
breakpoint specify the threshold point (page width) for switching between Mobile layout and PC layout
items.mobile the frontend component for implementing Mobile layout
items.pc the frontend component for implementing PC layout

See also:Adaptive Layout: PC = Mobile + Pad

markdown

The style module used when displaying markdown content. When the markdown content needs to be displayed, the system automatically loads the module asynchronously to make the style in the module effective

theme

Configuration of system theme

See also:Theme & Style

modules

Override the frontend configuration of the module here

See also:Override Module Config