- Click here for mock server documentation.
- Click here to see more changes reg the
@r35007/mock-server
package
- Readme update
- Updated -
@35007/[email protected]
node package.
- Updated -
@35007/[email protected]
node package. - Added -
.json5
support.
- Added -
Serve Static Files
- Right click on any file or folder in and select this command to serve the static files.
- Updated -
@35007/[email protected]
node package. - Added -
MockServer: Start Server in Terminal
- This command starts the mock server in terminal
- Updated -
@35007/[email protected]
node package. - Updated - mock-server example files.
- Added - explorer context menus.
- Updated -
@35007/[email protected]
node package.
- Updated -
@35007/[email protected]
node package.
- Updated -
@35007/[email protected]
node package. - Fixed - On server restart the db is not reflecting the changes and its caching issue fixed.
- Updated -
@35007/[email protected]
node package.
- Updated -
@35007/[email protected]
node package. - Support for
.cjs
,.mjs
andES module export
files.
- Updated -
@35007/[email protected]
node package. - Fixed - Transfer Encoding header issue fixed on
Make Request
command response.
- Fixed -
Make Request
response give a response time with doublems
prefixed issue fixed. - Fixed -
Start Server
stuck when the db path is not set issues fixed.
- Updated - Node package
@r35007/[email protected]
. - Added -
noCache
inmock-server.settings.defaults
settings. Set to false to Enable response caching.
- Build issue fix.
- Updated - Node package
@r35007/[email protected]
. - Fixed -
mock-server.settings.log
setting not working issue fixed.
- Modified - Server Output logs
- Fixed - Set config not setting injectors path issue fixed.
- Added -
Mock It
context menu to.har
file.
- Samples updated.
- Added - auto completion for
env-config.json
orenv-config.jsonc
.
- Samples updated.
- Fixed - Routes auto complete is not coming for
.js
and.ts
file issue fixed. - Fixed -
Set as Server Root Folder
is always setting at user level settings issues fixed.
- Updated -
@r35007/[email protected]
.
- Fixed -
.jsonc
files are not showing up in theSwitch Environment
quick pick list items issue fixed. - Increased font size for Home page.
- Added more auto completions and schema updates.
- Reverted using webpack build due to require file from outside the build not supported limitations.
- Added Auto completion of routes and configs.
- Provided JSON schema for
*db.js*
,*injectors.js*
,mock-server*.js*
,msconfig.js*
. - These above schema helps to autocomplete server config properties.
- Added -
Set as Server Root Folder
command in explorer context. - Added -
Start with New Port
command in command pallet. - Resolved - Sample files errors.
- Added -
Make Request
command. Helps to search endpoint and make get request to get the endpoint data.
- Restart the mock server on changes in environment data file.
- Support for JSON with comments.
- Added -
Mock It
command in context menu. Helps to run the current file data in mock server. - Added -
Switch Environment
command in context menu. - Build size reduced using webpack.
- Context menu show and hide issue fixed.
- Build size reduced
- Context menu grouped by publisher name.
- Build size reduced.
- Removed -
Set as Server Root Folder
is removed from context menu. - Added - Mock Server submenus in the editor context.
- Added -
mock-server.settings.contextMenu
- Helps to show or hide commands in context menu, - Updated - Right click on any
.json
file and selectStart Server
from context to start the mock server with the current file as anenv
file.
- Updated
@r35007/[email protected]
. - Added - Right click on any file and select
Paste Mock Server Config
to get the mock server current config used by vscode config.
- Updated
@r35007/[email protected]
. - samples update.
- Added - Right click on mock server config
.js
or.json
file and selectSet as Mock Server Config
to set the mock server config in vscode config.
- Updated
@r35007/[email protected]
. - samples update.
- Updated
@r35007/[email protected]
. - samples update.
- samples update.
- added - File icon on
Switch Environment
pick list. Helps to open selected db files.
- Updated
@r35007/[email protected]
.
- Fixed - Not restarting on changes on the fetch paths.
- Updated
@r35007/[email protected]
. - renamed
mock-server.settings.paths.middleware
tomock-server.settings.paths.middlewares
- renamed
_harEntryCallback
toharEntryCallback
- renamed
_harDbCallback
toharDbCallback
- renamed
_kibanaHitsCallback
tokibanaHitsCallback
- renamed
_kibanaDbCallback
tokibanaDbCallback
- renamed
_globals
toglobals
- Fixed - Transform to MockServer Db not working.
- Fixed - Transforming to MockServer Db not showing a valid error message.
- Improved - Environment pick list.
- Fixed - Server not starting with
none
environment.
- Fixed - Env not picking injectors and middlewares by default.
- Updated
@r35007/[email protected]
. - Fixed - Not Transforming if current text file is larger than 4mb.
- Updated
@r35007/[email protected]
. - renamed -
mock-server.settings.paths.envDir
tomock-server.settings.paths.environment
- renamed -
mock-server.settings.paths.staticDir
tomock-server.settings.paths.static
- renamed -
mock-server.settings.paths.snapshotDir
tomock-server.settings.paths.snapshots
- Updated
@r35007/[email protected]
. - Removed -
mock-server.settings.fullReload
. By default It always resets and restarts the server on changes.
- fixed -
Switch Environment
not working issue fixed. - added - progress bar for
Transform to Mock Server Db
,Get Db Snapshot
,Generate Sample Mock Files
.
- added - Create a custom database test environment using
env.config.json
. For Example:env/env.config.json
// These names will be listed in the environment pick list { "Your Environment Name": { "db": "./testDb.json", "injectors": "./testInjectors.json", "middlewares": "./testMiddlewares.js", "description": "Your description here" // This description will be shown in the switch environment pick list }, "Your New Environment Name": { "db": ["./testDb2.json", "./testDb2.json"] // Can also provide multiple paths } }
Note: All the paths given in the
env.config.json
will be relative to the path given inmock-server.settings.paths.environment
. File or Folder name withinjectors
andmiddlewares
will not list in the pick list.
- updated - Switch Environment pick list shows relative File path of the
env
directory. - removed -
Mock Server Config Logs
andMock Server Path Log
in output panel. Now both will show atMock Server Log
- updated - Switch Environment pick list shows relative File path of the
root
directory.
- updated -
@r35007/[email protected]
. - updated - Switch Environment pick list shows File path.
- updated -
@r35007/[email protected]
.
- updated -
@r35007/[email protected]
.
- updated -
@r35007/[email protected]
. - method in
env
folder file is not getting themockServer
instance -Fixed
- Code optimized.
- updated -
@r35007/[email protected]
.
- updated -
@r35007/[email protected]
. - added -
mock-server.settings.homePage
- If false, The Mock Server Home Page will not be served. Default: true.
- code optimized.
- removed MockServer: Reset -
mock-server.reset
command. - removed MockServer: Reset and Restart -
mock-server.resetAndRestart
command. - removed Start Server with New Port -
mock-server.startWithNewPort
command. - added
mock-server.settings.openHomePageInsideVSCode
- By default it open the homepage inside VS Code. If false it open in a default browser. - Home Page improved.
- Home Page not refreshing on start or stop of the server -
Fixed
mock-server.settings.dbMode
not working issue -Fixed
- Updated
@r35007/[email protected]
- added
multi
mode inmock-server.settings.dbMode
- removed
mock-server.settings.useLocalIp
- instead Leave it empty tomock-server.settings.host
to pick the local ip address.
- Updated
@r35007/[email protected]
- rewriters not working -
Fixed
- Updated
@r35007/[email protected]
- added
mock-server.settings.useLocalIp
- uses Local Ip address instead ofmock-server.settings.host
- added
mock-server.settings.fullReload
- If true it always resets and restarts the server on changes. - added
mock-server.settings.ignoreFiles
- Add list of files and folder path to ignore changes. - renamed
mock-server.settings.customWatchPaths
tomock-server.settings.watchFiles
- Set
mock-server.settings.port
to 0 (zero) to pick a dynamic available port.
- Updated
@r35007/[email protected]
- added
cookieParser
in default middlewares. - file watcher not stopping on server stop -
Fixed
- Updated
@r35007/[email protected]
- middleware callbacks are not working on
mock-server.transformToMockServerDB
command -Fixed
- config not updated when using
mockServer
insidemiddleware.js
exports -Fixed
- Updated
@r35007/[email protected]
- added
mock-server.startWithNewPort
command - Helps to set a new port and start the server - If already a server is running at the same port it prompts the user to give a new port and start the server
-
Updated
@r35007/[email protected]
-
added
mock-server.settings.dbMode
- Helps to set a direct value of a route tomock
orfetch
-
renamed
mock-server.settings.allowDuplicates
tomock-server.settings.iterateDuplicateRoutes
-
updated
mock-server.settings.watchForChanges
- Set to true to restart server on changes watched bymock-server.settings.customWatchPaths
-
added
mock-server.settings.customWatchPaths
- Provide your custom paths to watch for changes -
removed
mock-server.settings.environment
- maintained by localStorage -
added - On Start or Restart of the server the info popup comes with the link to open up the browser with the homepage
-
Now we pass the instance and config of the mockserver to the methods that are exported as a db, injectors etc... For Example :
db.js
module.exports = (mockServer, env) => { const db = { post: { userId: 1, id: 1, title: "New Post", }, }; return db; };
- Updated
@r35007/[email protected]
- Now we can give
.js
file in env folder
- Updated
@r35007/[email protected]
- Updated
@r35007/[email protected]
- Updated
@[email protected]
- Now we can export a function in db.js which will be called on start and restart of the mock server.
- Performance improvement
mock-server.settings.watchForChanges
- add custom paths to watch for file changes and restart server
- Readme update
- Updated
@r35007/[email protected]
entryCallback
is now renamed to_harEntryCallback
finalCallback
is now renamed to_harDbCallback
- Added
Set as Server Root folder
command. Helps to set current selected folder as a mock server root folder. Also available in context menu - Added
Reset Server
command. Helps to clear mock server cache a, gracefully stops server and reset server data. - Added
Reset and Restart Server
command. Helps to reset and restart the server with new server instance. - Added
Mock Server Paths Log
andMock Server Config Log
output log.
- Updated
@r35007/[email protected]
- Updated
@r35007/[email protected]
- Updated
@r35007/[email protected]
- Updated
@r35007/[email protected]
- Now can give .js file to the db, injectors, rewriters, store path
- Added
Set Port
Command which is also available in editor context.
- On clicking of Stop Server in editor context before starting the server makes the statusbar to show wrong info and become unable to start server -
Fixed
- Now Stop Sever in editor context will show only on
.json
and.har
file
- removed adding injectors config on transforming to Mock Server Db.
- Synced with
@r35007/mock-server
package.
mock-server.settings.paths.snapshotsDir
- Add a snapshot dir to get your d snapshots- Dynamically run any json file to start the server by right clicking and select
Start Server
in editor context. - Synced with
@r35007/mock-server
package.
- Stopping Server takes too long Bug fixed.
Generate Mock Files
Command added.- Added commands in editor context
- Restart Server bug fixed.
- License Update
- ReadMe update
- Implemented mock server
Home Page
inside vs code. - Added more settings
- Updated
@r35007/[email protected]
mock-server.settings.store
is renamed tomock-server.settings.paths.storePath
- updated
@r35007/[email protected]
- Bug Fix
- updated
@r35007/[email protected]
- changes default mockPath from
https://jsonplaceholder.typicode.com/db
tohttp://jsonplaceholder.typicode.com/db
- updated
@r35007/[email protected]
- Now can directly access server Mock data.
Try to give the following code in
settings.json
{
"mock-server.settings.paths": {
"mockPath": "https://jsonplaceholder.typicode.com/db"
}
}
- updated
@r35007/[email protected]
mock-server.resetServer
command bug fix.
- updated
@r35007/[email protected]
- Bug Fix
- updated
@r35007/[email protected]
- Bug Fix
- Added File watcher. Automatically restarts the server for file changes.
- updated
@r35007/[email protected]
- Initial release