yma-cli-dev
v1.0.42
Published
Webpack Dev 构建命令
Downloads
192
Readme
Http 方案
module.exports = {
'GET /api/xxx': {
code: 0,
message: 'success',
data: {},
},
'POST /api/update': (req, res) => {
res.send({
code: 200,
message: 'success',
});
},
};
Vite 方案
module.exports = [
{
url: '/api/xxx',
method: 'get', // default get
response: (req, res) => {
return {
code: 0,
message: '',
data: {},
};
},
},
];