Giter Site home page Giter Site logo

Add image to breadcrumb about ember-crumbly HOT 8 CLOSED

poteto avatar poteto commented on August 29, 2024
Add image to breadcrumb

from ember-crumbly.

Comments (8)

abhilashlr avatar abhilashlr commented on August 29, 2024 1

It should be in either

app/components/bread-crumbs/template.hbs
Or
app/templates/components/bread-crumbs.hbs

from ember-crumbly.

jhunflx avatar jhunflx commented on August 29, 2024 1

The correct path is app/components/bread-crumbs/template.hbs

Thank you for taking the time to point me in the right direction!

from ember-crumbly.

abhilashlr avatar abhilashlr commented on August 29, 2024

One can create a custom template in the same name as the add-on - Bread-crumbs.hbs

from ember-crumbly.

jhunflx avatar jhunflx commented on August 29, 2024

Where does this template reside? In the same directory as my route? Currently I have something like this:

controller.coffee
route.coffee
template.hbs
bread-crumbs.hbs

where template.hbs looks like this:

<div class="row wrapper border-bottom white-bg page-heading">
  <div class="col-md-10">
    <h2>{{bread-crumbs tagName="ol" outputStyle="bootstrap" linkable=false}}</h2>
  </div>
</div>
{{outlet}}

and bread-crumbs.hbs looks like this:

{{log breadCrumb}}
{{#bread-crumbs outputStyle="bootstrap" linkable=true as |component breadCrumb|}}
  {{#bread-crumb route=breadCrumb breadCrumbs=component}}
    <img src="/assets/images/cow.png" /> {{breadCrumb.title}}
  {{/bread-crumb}}
{{/bread-crumbs}}

but the code never hits {{log breadCrumb}} leading me to believe it's not getting called. Do you have any sample code of what this should look like?

Thanks!

from ember-crumbly.

abhilashlr avatar abhilashlr commented on August 29, 2024

Did it already work for you?

If not, can you try adding the bread-crumbs.hbs inside app/components/templates/ path?

from ember-crumbly.

jhunflx avatar jhunflx commented on August 29, 2024

Unfortunately not. I tried putting the file in app/components/templates as well as in my app/pods/components/templates.

Do you have an example of this working in your project that you can share?

from ember-crumbly.

abhilashlr avatar abhilashlr commented on August 29, 2024

Cool 😎

from ember-crumbly.

fsmanuel avatar fsmanuel commented on August 29, 2024

I'm closing this as the problem is solved.

from ember-crumbly.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.