debuggerHelper.js 813 B

1234567891011121314151617181920212223242526
  1. import Vue from "vue";
  2. export const debuggerHelper = (show = true) => {
  3. const version = "1.7.0--" + process.env.VUE_APP_DEBBUG_FLAG;
  4. if (show) {
  5. // log.setColors({
  6. var css = "background: #28b561; color:#fff;font-size:14px;padding:5px;";
  7. console.log(`%c 👉:当前版本::---> ${version}`, css);
  8. }
  9. if (Number(process.env.VUE_APP_DEBBUG_NOTIFY) === 1) {
  10. Vue.$toast.warning(`当前开发正在调试${version}中, 请等候!`, {
  11. position: "top-center",
  12. timeout: 400000,
  13. closeOnClick: true,
  14. pauseOnFocusLoss: true,
  15. pauseOnHover: true,
  16. draggable: true,
  17. draggablePercent: 0.6,
  18. showCloseButtonOnHover: false,
  19. hideProgressBar: true,
  20. closeButton: "button",
  21. icon: true,
  22. rtl: false,
  23. });
  24. }
  25. };