Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

allow theel option to accept anHTMLElement instance#1712

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Open
trusktr wants to merge4 commits intodevelop
base:develop
Choose a base branch
Loading
fromelement-value-for-el-option

Conversation

@trusktr
Copy link
Member

@trusktrtrusktr commentedJan 5, 2022
edited
Loading

Summary

Theel docs say

It can be a CSS selector string or an actualHTMLElement.

which wasn't true. This change updates the code to match the docs.

Additionally this allows Docsify to be embedded in custom elements or components systems like React/Vue/Solid/etc where normally people have a reference to an element.

What kind of change does this PR introduce?

Bugfix?
Feature?

For any code change,

  • Related documentation has been updated if needed
  • Related tests have been updated or tests have been added

Does this PR introduce a breaking change? (check one)

  • Yes
  • No

Related issue, if any:

Tested in the following browsers:

  • Chrome
  • Firefox
  • Safari
  • Edge
  • IE
  • jsdom

@vercel
Copy link

vercelbot commentedJan 5, 2022
edited
Loading

This pull request is being automatically deployed with Vercel (learn more).
To see the status of your deployment, click below or on the icon next to each commit.

🔍 Inspect:https://vercel.com/docsify-core/docsify-preview/GFgr7UN6pNmBGZEaRQrskSY52E5t
✅ Preview:https://docsify-preview-git-element-value-for-el-option-docsify-core.vercel.app

@trusktrtrusktr requested a review froma teamJanuary 5, 2022 17:50
@codesandbox-ci
Copy link

codesandbox-cibot commentedJan 5, 2022
edited
Loading

This pull request is automatically built and testable inCodeSandbox.

To see build info of the built libraries, clickhere or the icon next to each commit SHA.

Latest deployment of this branch, based on commitc8141f7:

SandboxSource
docsify-templateConfiguration

This aligns it with what the docs were already saying erroneously, plusthis is useful in cases when people have refs to an element already(embedding Docsify in a custom element shadow root, or in a Reactcomponent that has a ref to the target element, etc).
@trusktr
Copy link
MemberAuthor

trusktr commentedJan 7, 2022
edited
Loading

I realized thatdom.getNode() has similar logic as what I implemented here. Using that would make this PR shorter.

  • use dom.getNode instead

@trusktrtrusktr removed the request for review froma teamJanuary 10, 2022 03:42
@trusktrtrusktr requested a review froma teamJanuary 26, 2022 16:57
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment

Reviewers

No reviews

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

2 participants

@trusktr

[8]ページ先頭

©2009-2025 Movatter.jp