Skip to content

errors when there are hashes in url #6

@zaszlo

Description

@zaszlo

Hello,

I have components in the page that are called using hashes (those id/anchors are not inside md), the page loads but I get these errors, my console is bloated with them:

Uncaught DOMException: Failed to execute 'querySelector' on 'DocumentFragment': '#1' is not a valid selector.
at HTMLElement._scrollTo (https://cdn.rawgit.com/zerodevx/zero-md/v1.1.0/build/zero-md.html:1:4077)
    at window.setTimeout (https://cdn.rawgit.com/zerodevx/zero-md/v1.1.0/build/zero-md.html:1:967)

_scrollTo | @ | zero-md.html:1
-- | -- | --
  | window.setTimeout | @ | zero-md.html:1
  | setTimeout (async) |   |  
  | a | @ | zero-md.html:1
  | _fire | @ | zero-md.html:1
  | Promise.all.then | @ | zero-md.html:1
  | Promise.then (async) |   |  
  | render | @ | zero-md.html:1
  | connectedCallback | @ | zero-md.html:1
  | append | @ | swiper.js:634
  | loopCreate | @ | swiper.js:2255
  | h.init | @ | swiper.js:3961
  | h | @ | swiper.js:3854
  | (anonymous) | @ | (index):187

Is there a way to fix it?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions