poteto / ember-crumbly

Declarative breadcrumb navigation for Ember apps
MIT License
167 stars 78 forks source link

Adding BreadcrumbList schema.org spec #119

Open kiwiupover opened 7 years ago

kiwiupover commented 7 years ago

Closes #118

Usage:

{{bread-crumbs hasSchema=true}}

TODO

https://developers.google.com/search/docs/data-types/breadcrumbs http://schema.org/BreadcrumbList

output from foo/bar/baz route

Validate the output here https://search.google.com/structured-data/testing-tool

<ol id="hasSchema" itemscope="" itemtype="http://schema.org/BreadcrumbList" class="ember-view breadcrumb">
  <li id="ember469" itemprop="itemListElement" itemscope="" itemtype="http://schema.org/ListItem" class="ember-view">
    <a id="ember470" href="/foo" itemscope="" itemtype="http://schema.org/Thing" itemprop="item" class="ember-view"> <span itemprop="name">
            I am Foo Index
          </span>
    </a>
    <meta itemprop="position" content="1">
  </li>
  <li id="ember472" itemprop="itemListElement" itemscope="" itemtype="http://schema.org/ListItem" class="ember-view">
    <a id="ember473" href="/foo/bar" itemscope="" itemtype="http://schema.org/Thing" itemprop="item" class="ember-view active"> <span itemprop="name">
            I am Bar
          </span>
    </a>
    <meta itemprop="position" content="2">
  </li>
  <li id="ember475" itemprop="itemListElement" itemscope="" itemtype="http://schema.org/ListItem" class="ember-view"> <span itemprop="name">
        I am Baz
      </span>
    <meta itemprop="position" content="3">
  </li>
</ol>

@trabus thanks for your help!!

kiwiupover commented 7 years ago

@poteto I thinks this is a good start. There are a couple of issues which I will comment in the code.

Is there no CI?