Skip to content
This repository has been archived by the owner on Mar 28, 2022. It is now read-only.

Release v2.0.0 #130

Merged
merged 141 commits into from
Feb 17, 2021
Merged

Release v2.0.0 #130

merged 141 commits into from
Feb 17, 2021

Conversation

javierbrea
Copy link
Member

Added

Changed

  • feat: Improve traces when checking plugin options
  • refactor: Move path and watch options inside files-loader plugin
  • refactor: Reorganize files and folders
  • refactor: Refactor Loaders to receive specific onLoad callback instead of full core instance
  • refactor: Refactor Config to receive a single argument with all options
  • refactor: Refactor Plugins to receive a single argument with all options

Fixed

  • fix: Boolean options with default value of true were not working when defined as false in config file

Removed

  • feat: Do not add no behaviors alert. As behaviors are legacy in v2, now it is not considered a problem

BREAKING CHANGES

  • feat: Renamed configuration file from mocks-server.config.js to mocks.config.js
  • feat: Remove deprecated options features and behaviors, path option should be used instead
  • feat: Remove deprecated option feature, behavior option should be used instead
  • feat: Legacy mocks defined using v1 format have to be loaded from folder defined using option pathLegacy instead of path, which now is used to define the folder from which load routes and mocks in v2 format. Folder defined with pathLegacy option will not be created automatically if it is not found, and the option is not required
  • feat: Watching files for mocks in legacy v1 format has to be disabled using watchLegacy option instead of watch, which now affects only to routes and mocks in v2 format
  • feat: watch option now is a standard commander boolean, so, to disable watch, argument --no-watch has to be provided. (--no-watchLegacy for legacy v1 mocks folder) (closes Negative options format #107)
  • feat: Remove booleanString option type. Now only number, boolean or string can be used.
  • feat: Remove deprecated onLoadMocks method, onChangeMocks must be used instead
  • feat: Remove onLoadFiles method. There is no alternative, as it is an internal event of the files-loader plugin and it should't be used by other external pieces
  • feat: Legacy mocks have to be loaded using plugins custom method loadLegacyMocks. loadMocks will be able to handle only v2 mocks
  • feat: Listening to changes on legacy mocks has to be added using onChangeLegacyMocks instead of onChangeMocks, which only is triggered when v2 mocks change
  • feat: Remove Accept and language default headers
  • feat: Remove addCustomRouter method. addRouter has to be used instead
  • feat: Remove addCustomSetting method. addSetting has to be used instead
  • feat: Remove features getter from Server. legacy behaviors has to be used instead
  • feat: Remove serverError getter. Use alerts instead
  • feat: Remove restart method, use restartServer instead

renovate-bot and others added 30 commits December 25, 2020 10:36
…tier-6.x

chore(deps): update dependency eslint-config-prettier to v6.15.0
…on. Move watch option inside files-loader plugin
… new Mock, receives routes and mocks, and create express router
chore(deps): update dependency husky to v4.3.8
renovate-bot and others added 29 commits February 12, 2021 16:20
fix(deps): update dependency node-watch to v0.7.1
…tier-7.x

chore(deps): update dependency eslint-config-prettier to v7
chore(deps): update dependency eslint to v7.20.0
@javierbrea javierbrea merged commit 9df60d4 into master Feb 17, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
2 participants