Background

Because the module development of CabloyJS follows the principle of opening and closing, in actual projects, project level parameters can be used to override module level parameters, so that we can customize module behavior parameters from the project level

Override Module Config

Since CabloyJS has three built-in running environments, you can configure parameters in the config file of the appropriate running environment as needed. For example, we need to modify the parameters in the module test-party to take effect in all running environments. Then we need to modify the file config.default.js

src/backend/config/config.default.js

  1. 1// modules
  2. 2config.modules = {
  3. 3 'test-party': {
  4. 4 message: 'Hello World!',
  5. 5 },
  6. 6};