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

Add docsify version to $window.docsify object #641

Merged
merged 2 commits into from
Oct 23, 2018
Merged

Add docsify version to $window.docsify object #641

merged 2 commits into from
Oct 23, 2018

Conversation

jhildenbiddle
Copy link
Member

Fix #521

Please makes sure these boxes are checked before submitting your PR, thank you!

  • [ x ] Make sure you are merging your commits to master branch.
  • [ x ] Add some descriptions and refer relative issues for you PR.
  • [ x ] DO NOT include files inside lib directory.

@QingWei-Li QingWei-Li merged commit 94bc415 into docsifyjs:master Oct 23, 2018
@QingWei-Li
Copy link
Member

I forgot to get the version before by Docsfiy.version

Docsify.version = '__VERSION__'

😂

@jhildenbiddle jhildenbiddle deleted the fix/521 branch November 1, 2018 22:28
@jhildenbiddle jhildenbiddle restored the fix/521 branch November 1, 2018 22:45
@jhildenbiddle
Copy link
Member Author

jhildenbiddle commented Nov 1, 2018

@QingWei-Li --

The altered implementation does not work. There is no version key available on the Docsify object. The goal is to have the version number accessible from the browser environment to allow plugins to behave differently based on the version.

An easy test is to try to access the version value from the console in a browser. With my implementation, the version was available via $docsify.version. With your altered implementation you've moved it to the Docsify object, so it should be availalbe at Docsify.version.

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

Successfully merging this pull request may close these issues.

None yet

2 participants