Giter Site home page Giter Site logo

Comments (8)

ZhengXiaowei avatar ZhengXiaowei commented on May 18, 2024 3

目前来说:

  • 路由的起始页必须是首页 (测试其他路由为routes的第一项时无效)
  • 路由内部是否有做过正则校验 (我在routes里写正则匹配失效,带有参数的路由的处理,写骨架的时候切换不过去,可能是因为我数据已经带入的问题)
  • 估计是针对静态资源生成的,就是如果数据是后台过来的,那么和数据关联的dom,将不会自动生成骨架元素 (这里是我通过本地静态骨架的方式,通过静态骨架生成ssr骨架,静态骨架会在数据获取成功并渲染后移除,然后再渲染页面。)
  • 骨架元素html保存后,下次运行能否先运用保存的骨架再做修改 (我这测试时,每次进入估计preview.html后,都是根据dom自动重新生成的骨架,而不是我上次保存的骨架html,不知道是不是我设置的问题)

暂时这些,之后还有再提哈~

from page-skeleton-webpack-plugin.

ZhengXiaowei avatar ZhengXiaowei commented on May 18, 2024 1

忙着公司项目重构。。最近打算接入这个插件正式弄弄,然后再看看能否提出些改进和想法

from page-skeleton-webpack-plugin.

Jocs avatar Jocs commented on May 18, 2024

@ZhengXiaowei 最近我没有太多时间维护这个项目,你有什么想法吗?

from page-skeleton-webpack-plugin.

wookaoer avatar wookaoer commented on May 18, 2024

@ZhengXiaowei 最近我没有太多时间维护这个项目,你有什么想法吗?

大佬最近对hash模式的支持有啥想法吗,可以探讨探讨

from page-skeleton-webpack-plugin.

Jocs avatar Jocs commented on May 18, 2024

@wookaoer 在路由配置的时候支持 hash?

from page-skeleton-webpack-plugin.

wookaoer avatar wookaoer commented on May 18, 2024

@Jocs 我看插件逻辑是根据路由path分目录对应生成各个路由的骨架页面,这个逻辑在history mode下是没问题的,因为nginx 可以直接通过这个uri路由到对应的静态资源。比如.b.com/xx/xx请求就直接到了/dist/xx/xx/index.html。但是hash mode下#后面的path是不会被带到n服务端的,所以没法路由。

所以问题就是针对hash mode的应用怎么做打包构建

from page-skeleton-webpack-plugin.

Jocs avatar Jocs commented on May 18, 2024

from page-skeleton-webpack-plugin.

luobinhang avatar luobinhang commented on May 18, 2024

目前来说:

  • 路由的起始页必须是首页(测试其他路由为routes的第一项时无效)
  • 路由内部是否有做过正则校验(我在routes里写正则匹配失效,带有参数的路由的处理,写骨架的时候切换不过去,可能是因为我数据已经带入的问题)
  • 估计是针对静态资源生成的,就是如果数据是后台过来的,那么和数据关联的dom,将会通过本地静态骨架的方式,通过静态骨架生成ssr骨架,静态骨架会在数据获取成功并渲染后移除,然后再渲染页面。)
  • 骨架元素html保存后,下次运行能否先运用保存的骨架再做修改(我这测试时,每次进入估计preview.html后,都是根据dom自动重新生成的骨架,而不是我上次保存的骨架HTML,不知道是不是我设置的问题)

暂时这些,之后还有再提哈〜

希望可以支持一下hash, 你收集的这些问题都是目前比较需要的

from page-skeleton-webpack-plugin.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.