Giter Club home page Giter Club logo

Comments (9)

farling42 avatar farling42 commented on September 3, 2024

from obsidian-import-json.

farling42 avatar farling42 commented on September 3, 2024

Note that in your handlebars you reference "entries" directly, but that is another array, so you will need another forEach block to read each individual entry in that array (even though there is only one, you still need to access it like an array of more than one). Something similar to:

{{#forEach entriesHigherLevel}}
## At Higher Levels
{{#forEach this.entries}}
this
{{/forEach}}
{{/forEach}}

from obsidian-import-json.

AmbushXXVI avatar AmbushXXVI commented on September 3, 2024

Hrm. Thanks for pointing out that I'd missed that inner block. Unfortunately, I can't seem to get a forEach to work anywhere. I also tried with the fromClassListVariant, but I'm still getting the same createFrame error.

Class Variants (forEach): {{#forEach classes.fromClassListVariant}}{{this.name}} {{/forEach}}

from obsidian-import-json.

AmbushXXVI avatar AmbushXXVI commented on September 3, 2024

So, not sure what's going on, but I tried using #each instead of the helper #forEach and it worked. Unfortunately, I don't really know if this will have any other effects down the line...

Update: Ahh. So other helper functions like isLast don't work with each.

from obsidian-import-json.

AmbushXXVI avatar AmbushXXVI commented on September 3, 2024

Any chance you've had time and inclination to look at this? Still trying to figure out if it's my code, my source, or something in the import tool.

Thanks

from obsidian-import-json.

farling42 avatar farling42 commented on September 3, 2024

I just had a look, and #forEach is broken in my distribution.
I am trying to find how to include the required modules to get that working properly.

from obsidian-import-json.

ckennedy666 avatar ckennedy666 commented on September 3, 2024

It looks like match from Handlebars-Helpers is also missing some modules, perhaps related.

from obsidian-import-json.

farling42 avatar farling42 commented on September 3, 2024

I've changed the plugin to use a fork of handlebars-helpers (see https://github.com/Budibase/handlebars-helpers) which builds properly.
This means that #forEach should now work properly in 0.12.0

from obsidian-import-json.

AmbushXXVI avatar AmbushXXVI commented on September 3, 2024

thanks for taking the time to fix this :)

from obsidian-import-json.

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.