Skip to content

Instantly share code, notes, and snippets.

View avatarvb's full-sized avatar
🏠
Working from home

avatarvb

🏠
Working from home
View GitHub Profile
@pheuter
pheuter / gist:3515945
Created August 29, 2012 17:33
Handlebars.js equality check in #if conditional

Handlebars.js is a template framework for Javascript environments. It allows the construction of HTML elements using HTML and expressions wrapped in {{ }}

Limitations of {{if}}

One of the conditional block helpers Handlebars offers is the {{#if}}.

For example:

<div class="entry">
@flistefliste
flistefliste / MaterializeCSS datepicker in french
Last active April 3, 2023 23:15
French translation for Materialize CSS datepicker plugin
$('.datepicker').pickadate({
selectMonths: true, // Creates a dropdown to control month
selectYears: 2, // Creates a dropdown of 15 years to control year
labelMonthNext: 'Mois suivant',
labelMonthPrev: 'Mois précédent',
labelMonthSelect: 'Selectionner le mois',
labelYearSelect: 'Selectionner une année',
monthsFull: [ 'Janvier', 'Février', 'Mars', 'Avril', 'Mai', 'Juin', 'Juillet', 'Août', 'Septembre', 'Octobre', 'Novembre', 'Décembre' ],
monthsShort: [ 'Jan', 'Fev', 'Mar', 'Avr', 'Mai', 'Jun', 'Jul', 'Aou', 'Sep', 'Oct', 'Nov', 'Dec' ],
weekdaysFull: [ 'Dimanche', 'Lundi', 'Mardi', 'Mercredi', 'Jeudi', 'Vendredi', 'Samedi' ],