mirror of
https://github.com/certd/certd.git
synced 2026-05-15 12:37:30 +08:00
feat: 升级前端框架,适配手机端
This commit is contained in:
@@ -1,10 +1,10 @@
|
||||
import * as _ from "lodash-es";
|
||||
import { isArray } from "lodash-es";
|
||||
export default {
|
||||
arrayToMap(array: any) {
|
||||
if (!array) {
|
||||
return {};
|
||||
}
|
||||
if (!_.isArray(array)) {
|
||||
if (!isArray(array)) {
|
||||
return array;
|
||||
}
|
||||
const map: any = {};
|
||||
@@ -19,7 +19,7 @@ export default {
|
||||
if (!map) {
|
||||
return [];
|
||||
}
|
||||
if (_.isArray(map)) {
|
||||
if (isArray(map)) {
|
||||
return map;
|
||||
}
|
||||
const array: any = [];
|
||||
|
||||
@@ -1,5 +1,8 @@
|
||||
// @ts-ignore
|
||||
import * as _ from "lodash-es";
|
||||
import {forEach} from "lodash-es";
|
||||
export function getEnvValue(key: string) {
|
||||
// @ts-ignore
|
||||
return import.meta.env["VITE_APP_" + key];
|
||||
}
|
||||
|
||||
export class EnvConfig {
|
||||
MODE: string = import.meta.env.MODE;
|
||||
|
||||
Reference in New Issue
Block a user