question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

[Feature request] embed docsify on third party site

See original GitHub issue

Docsify is great but I find I can only use it in a dedicated website. It would be more flexible if docsify can be embedded on other sites. Although it’s possible in theory but in practice I found that it doesn’t work well.

For example: I wanted to use docsify to generate the documentation on this site:

https://uis-azr-test-fusionapi-eus1.portal.azure-api.net/user-guide-2

When I embedded docsify into the html if found that it completely changed the layout of my website. I think one of the reasons is that it modified the nav of the website.

I ended up using flatdoc which doesn’t have the same features but it’s less intrusive on the host website.

Issue Analytics

  • State:open
  • Created 4 years ago
  • Reactions:5
  • Comments:6 (3 by maintainers)

github_iconTop GitHub Comments

4reactions
trusktrcommented, Jan 12, 2022

With the refactors that I recently did to move Docsify into its own file that has no side-effect of automatically loading Docsify into the DOM (see src/core/Docsify.js), I can imagine a simple way to do this initially as a non-breaking change (no custom element in this case), so I’ll put it in 4.x.

Basically, we just tell Rollup to compile an additional bundle using src/core/Docsify.js as the entry point. In this case, the user can place a script tag pointing to this new bundle and manually instantiate new Docsify, while the previous bundle will still exist so all existing sites work the same way.

Users of the new bundle will be able to do this:

new Docsify({
  el: '#somewhere',
})

This will be very handy for integrating into existing websites while keeping them single-page apps, for example.

0reactions
pauldrapercommented, Jan 12, 2022

Modifying the URL path is fine (for me at least).

But I do need to teardown listeners, or at least not cause a memory leak by double registering them.

I haven’t looked at the implementation.

Read more comments on GitHub >

github_iconTop Results From Across the Web

docsify
A magical documentation site generator. Simple and lightweight; No statically built html files; Multiple themes. GitHub Getting Started.
Read more >
Integrating Swagger UI with the rest of your docs
It's pretty easy to embed Swagger into an HTML page — just copy the ... Readme.com requires third-party hosting, but some other doc...
Read more >
Docsify - LeadGen App
Docsify LeadGen App Docsify is a chrome extension for Gmail and G Suite that tracks email opens, link clicks, attachment downloads, and per-page...
Read more >
Read the Docs Documentation
One from GitHub, telling you that “A third-party OAuth application ... Note: Our commercial site offers some extra features, like support ...
Read more >
Search Results - CVE
This vulnerability allows users to embed arbitrary JavaScript code in the Web UI ... As a workaround, disallow loading JavaScript from 3rd party...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found