tollmanz / backbone-wordpress-theme Goto Github PK
View Code? Open in Web Editor NEWA stripped down example of a WordPress theme that utilizes Backbone.js
A stripped down example of a WordPress theme that utilizes Backbone.js
I am working on a new wordpress theme that works on Backbone.MarionetteJS and requireJS.
any permalink structure will be acceptable by theme structure.
First off, thank you so much for putting this together! Super helpful way to get started on a WP backbone based theme.
I have been extending out the base theme you provide in this repo, but I seem to have hit a major roadblock. Currently no matter what I do I cannot loop through arrays in my templates.
Even something basic like:
{{ _.each([0,1,2,3,4], function(i) { }}
THIS IS A MEMBER
{{ }); }}
I have tried all sorts of different variations on an each loop such as {{#each data.teamMembers }} but no love so far.
In my app.js I have _.templateSettings = { interpolate: /{{=(.+?)}}/g, evaluate: /{{(.+?)}}/g, };
which should in theory allow me to loop items using something like:
{{ _.each(data.teamMembers, function(val,i){ }}
Any insight on what I may be able to do in order to loop through data coming from the model?
thanks in advance for any advice you may be able to provide!
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.