Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG]修改布局样式,刷新页面不生效,只有清除浏览器缓存才能生效 #33

Open
wangkailun opened this issue Jul 21, 2023 · 1 comment
Labels
enhancement New feature or request

Comments

@wangkailun
Copy link

修改文件内容如下:

//文件目录 src\app\@shared\layouts\da-layout\default-layout.config.ts

import { DaLayoutConfig } from './da-layout.type';
import { WIDE_LAYOUT_CONFIG ,WATERFALL_LAYOUT_CONFIG,TOP_NAV_LAYOUT_CONFIG, COMMON_LAYOUT_CONFIG  } from './da-layout.config'

export const DEFAULT_LAYOUT_CONFIG: DaLayoutConfig = COMMON_LAYOUT_CONFIG;
//{
//   id: 'leftRight',
//   mode: 'sidebarTop',
//   header: {
//     fixed: true,
//     firHeader: {
//       height: 60
//     },
//     secHeader: {
//       hidden: true
//     },
//     hidden: false
//   },
//   sidebar: {
//     fixed: true,
//     firSidebar: {
//       width: 240
//     },
//     secSidebar: {
//       hidden: true
//     },
//     hidden: false
//   },
//   footer: {
//     hidden: false
//   },
//   hideLogo: false
// };

看起来是项目启动后会把这部分配置吃到浏览器的 Local Storage,但是刷新页面并没有重新去reload 这个配置。

@GreatZPP GreatZPP added the enhancement New feature or request label Sep 13, 2023
@ricenoddle
Copy link
Collaborator

ricenoddle commented Sep 13, 2023

是的我们会再localStorage里保存当前的布局,如果直接修改的话需要清除缓存再刷新生效,代码中有提供 updateLayoutConfig 可以修改布局,后续我们优化一下

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants