Mockcat, a front – and back-end separate development tool set

Mockcat, a front – and back-end separate development tool set

2022-09-05 0 1,191
Resource Number 38083 Last Updated 2025-02-24
¥ 0USD Upgrade VIP
Download Now Matters needing attention
Can't download? Please contact customer service to submit a link error!
Value-added Service: Installation Guide Environment Configuration Secondary Development Template Modification Source Code Installation

The Mockcat recommended in this issue is a tool set for front-end separation development.

Project Introduction

Mockcat provides modular management of Mock data, definition and testing of interface data (support for JSON5/XML document formats, Mock.js syntax rules), operation logs of Mock data, and Mock service capabilities for data. In addition, it also provides some tools commonly used in development and a collection of tool classes of the website.

Mock test

A MOCK test is a test method that is created with a dummy object during testing for some object that is not easy to construct or obtain.

Installation and operation

  1. Install Node.js
  2. Execute the following command from the console:
>  npm install

>  npm start

If running a compressed version, set debug in config.js to false, then run npm run build, then npm start.

Instructions

1. Add Mock data module

Click the Add Module button to add a new Mock data module. The added data module can be modified or deleted. Click Version History to view the modified version of the Mock data. Click Proxy Configuration (displayed as the port number) to configure the port of the Mock and the URL of the route (omit the module name when using the Mock data, keeping it consistent with the developed URL, for example: /=> /example/).

Mockcat, a front – and back-end separate development tool set插图

2.Mock data file editing

Click the module name in the MOCK data Edit page to go to the Mock data edit page. The Mock data is stored in a file system that corresponds to the URL path and operates on the Mock data in the same way as the file. Select the node of the directory tree, you can add, modify or delete the node, click the “copy” button, you can choose different operations in the list to copy data, files or folders. Click [Export] button, you can choose to export the incoming and outgoing POJO files. Click Test to test the native Mock interface (similar to Postman, but with support for JSON5 and XML formatting and annotations), and click Link address to view a list of Mock data or files.

Mockcat, a front – and back-end separate development tool set插图1

3. Mock data editor

Mock data directory only supports data in JSON and XML format, you can add annotations to JSON and XML data. It is common to add comments to the file (to describe the interface), but it is also possible to comment the field (to describe the meaning of the field). Note: /**/ and < ! —-> Comments cannot be nested, and both comments and data editing can be performed using shortcut keys, as shown in the shortcut keys list below.

Mockcat, a front – and back-end separate development tool set插图2

Full screen and Find replacement

Mockcat, a front – and back-end separate development tool set插图3

List and Edit preview

4. Mock interface testing

JSON and XML data files stored in the system can be used to test local API interfaces. Click [Test]. A dialog box will pop up to test the Mock interface. The URL, Method, Headers, and incoming parameters from the template will be filled directly into the corresponding input box. The first URL uses http://127.0.0.1:8080 as the default server address. You can manually change the URL to the actual API server address. The URL will be recorded in the Cookie. If the interface to be tested requires login authentication, you need to log in to the interface before testing it.

Mockcat, a front – and back-end separate development tool set插图4

5. Mock service for data

During the development process, both front-end and back-end development can negotiate to modify the interface data structure, and the edited Mock can be used for front-end development pages. Select a different directory node and click [link address] to see the Mock data (you can omit the extension) , as shown in the figure. After the background development is completed, the server address can be switched to the development server for debugging, and the status parameter can be added to the address to specify the returned status code. Note: The editor validates JSON and XML data against the JSON5 and XML standards, respectively, and can only save and convert Mock data if it conforms to the standards.

Mockcat, a front – and back-end separate development tool set插图5

Mockcat, a front – and back-end separate development tool set插图6
资源下载此资源为免费资源立即下载
Telegram:@John_Software

Disclaimer: This article is published by a third party and represents the views of the author only and has nothing to do with this website. This site does not make any guarantee or commitment to the authenticity, completeness and timeliness of this article and all or part of its content, please readers for reference only, and please verify the relevant content. The publication or republication of articles by this website for the purpose of conveying more information does not mean that it endorses its views or confirms its description, nor does it mean that this website is responsible for its authenticity.

Ictcoder Free source code Mockcat, a front – and back-end separate development tool set https://ictcoder.com/kyym/mockcat-a-front-and-back-end-separate-development-tool-set.html

Share free open-source source code

Q&A
  • 1, automatic: after taking the photo, click the (download) link to download; 2. Manual: After taking the photo, contact the seller to issue it or contact the official to find the developer to ship.
View details
  • 1, the default transaction cycle of the source code: manual delivery of goods for 1-3 days, and the user payment amount will enter the platform guarantee until the completion of the transaction or 3-7 days can be issued, in case of disputes indefinitely extend the collection amount until the dispute is resolved or refunded!
View details
  • 1. Heptalon will permanently archive the process of trading between the two parties and the snapshots of the traded goods to ensure that the transaction is true, effective and safe! 2, Seven PAWS can not guarantee such as "permanent package update", "permanent technical support" and other similar transactions after the merchant commitment, please identify the buyer; 3, in the source code at the same time there is a website demonstration and picture demonstration, and the site is inconsistent with the diagram, the default according to the diagram as the dispute evaluation basis (except for special statements or agreement); 4, in the absence of "no legitimate basis for refund", the commodity written "once sold, no support for refund" and other similar statements, shall be deemed invalid; 5, before the shooting, the transaction content agreed by the two parties on QQ can also be the basis for dispute judgment (agreement and description of the conflict, the agreement shall prevail); 6, because the chat record can be used as the basis for dispute judgment, so when the two sides contact, only communicate with the other party on the QQ and mobile phone number left on the systemhere, in case the other party does not recognize self-commitment. 7, although the probability of disputes is very small, but be sure to retain such important information as chat records, mobile phone messages, etc., in case of disputes, it is convenient for seven PAWS to intervene in rapid processing.
View details
  • 1. As a third-party intermediary platform, Qichou protects the security of the transaction and the rights and interests of both buyers and sellers according to the transaction contract (commodity description, content agreed before the transaction); 2, non-platform online trading projects, any consequences have nothing to do with mutual site; No matter the seller for any reason to require offline transactions, please contact the management report.
View details

Related Article

make a comment
No comments available at the moment
Official customer service team

To solve your worries - 24 hours online professional service