docsify icon indicating copy to clipboard operation
docsify copied to clipboard

‘formatUpdated’ didn't work when deployed

Open pfeak opened this issue 3 years ago • 6 comments

Bug Report

When deploying docs via netlify, it is found that when using formatUpdated, {docsify-updated} is not rendered as expected. Local testing does not have this problem.

Steps to reproduce

add formatUpdated to the windows.$docsify

window.$docsify = {
  coverpage: false,
  loadSidebar: false,
  loadNavbar: false,
  formatUpdated: "{MM}/{DD} {HH}:{mm}"
};

add {docsify-updated} to README.md file

# Home

This is Home Page.

> Last Modified {docsify-updated}

What is current behaviour

{docsify-updated} is rendered as expected

What is the expected behaviour

{docsify-updated} is not rendered as expected

Other relevant information

  • [ ] Bug does still occur when all/other plugins are disabled?

  • Your OS: Windows10

  • Node.js version: v12.16.1

  • npm/yarn version: 6.13.4

  • Browser version: Chrome(102.0.5005.63)

  • Docsify version: 4.4.4

  • Docsify plugins: None

Please create a reproducible sandbox

Edit 307qqv236

Mention the docsify version in which this bug was not present (if any)

Local test or manual deployment on vps.

pfeak avatar Jun 03 '22 05:06 pfeak

Check for the presence of last-modified in the response header image

sy-records avatar Jun 03 '22 05:06 sy-records

screenshot taken from here https://codesandbox.io/s/romantic-frost-syhtpv

ERV`G3GSDSOTJ S)C3~761B

SW_NU$ YU%GR7AVRGS`07

pfeak avatar Jun 03 '22 05:06 pfeak

the same as netlify.

pfeak avatar Jun 03 '22 05:06 pfeak

Your md file does not have a last-modified header

sy-records avatar Jun 05 '22 05:06 sy-records

Thanks a lot for your answer. So how can I solve this problem through the settings when deploying docsfiy to netlify or CodeSandbox?

Edit 307qqv236

pfeak avatar Jun 05 '22 06:06 pfeak

I'm not sure about netlify and CodeSandbox, but if you're using GItHub Pages, take a look at https://github.com/docsifyjs/docsify/issues/1157#issuecomment-890467244

sy-records avatar Jun 19 '22 09:06 sy-records