- 更新所有文件的导入和导出语法,使用 ES6 模块格式 - 修改 package.json,添加 "type": "module" 配置 - 调整部分代码结构以适应 ES6 模块
24 lines
578 B
JavaScript
24 lines
578 B
JavaScript
// messages.js
|
|
export default {
|
|
user: {
|
|
// 成功消息
|
|
created: 'user created',
|
|
updated: 'user updated',
|
|
deleted: 'user deleted',
|
|
login: 'login successful',
|
|
logout: 'logout successful',
|
|
exists: 'user exists',
|
|
|
|
// 错误消息
|
|
not_found: 'user not found',
|
|
alreadyExists: 'user already exists',
|
|
accountPasswordNotMatch: 'account and password not match',
|
|
accountNotMatch: 'account not match',
|
|
passwordNotMatch: 'password not match',
|
|
passwordIncorrect: 'password incorrect'
|
|
},
|
|
server: {
|
|
error: 'server error'
|
|
}
|
|
}
|