1. walrus
A bolder kind of mustache.
walrus
Package: walrus
Created by: jeremyruppel
Last modified: Tue, 28 Jun 2022 21:38:54 GMT
Version: 0.10.1
License: MIT
Downloads: 2,289
Repository: https://github.com/jeremyruppel/walrus

Install

npm install walrus
yarn add walrus

Walrus

Build Status

Goal

  • Write a mustache templating language that fits more with the idea of view-objects as opposed to view-helpers

  • Support method helpers fully. This means:

    • (Semi)-Automatic invocation.
    • "Write what you mean" when it comes to functions.
    • Multiple arguments
    • Arguments may be primitive types
    • Ability to add in custom domain methods at the view object level (how do we do this?)
    • Still support helper methods and block helpers, but put the helper methods where they make the most sense
  • Support object paths like handlebars does

  • Make it easy to traverse back up to root, and to read as such

  • More to come...

Ideas

  • @ means this, like in coffeescript. This makes it easy to reference the root object context from anywhere.
  • do/end style blocks make more sense than # and / to me

Filter Packages

  • walrus.string: capitalization, casing, hyphenization, etc
  • walrus.inflection: pluralization, etc
  • walrus.date: date formatting
  • walrus.domain: bring raw json objects into the client domain (perhaps theres a better name for this)

RELATED POST

10 Must-Know Windows Shortcuts That Will Save You Time

10 Must-Know Windows Shortcuts That Will Save You Time

Arrays vs Linked Lists: Which is Better for Memory Management in Data Structures?

Arrays vs Linked Lists: Which is Better for Memory Management in Data Structures?

Navigating AWS Networking: Essential Hacks for Smooth Operation

Navigating AWS Networking: Essential Hacks for Smooth Operation

Achieving Stunning Visuals with Unity's Global Illumination

Achieving Stunning Visuals with Unity's Global Illumination

Nim's Hidden Gems: Lesser-known Features for Writing Efficient Code

Nim's Hidden Gems: Lesser-known Features for Writing Efficient Code